Which code segment should you use?

You are developing an auditing application to display the trusted ClickOnce applications that are installed on a computer.
You need the auditing application to display the origin of each trusted application.
Which code segment should you use?

You are developing an auditing application to display the trusted ClickOnce applications that are installed on a computer.
You need the auditing application to display the origin of each trusted application.
Which code segment should you use?

A.
ApplicationTrustCollection trusts;
trusts = ApplicationSecurityManager.UserApplicationTrusts;
foreach (ApplicationTrust trust in trusts)
{
Console.WriteLine(trust.ToString());
}

B.
ApplicationTrustCollection trusts;
trusts = ApplicationSecurityManager.UserApplicationTrusts;
foreach (ApplicationTrust trust in trusts)
{
Console.WriteLine(trust.ExtraInfo.ToString());
}

C.
ApplicationTrustCollection trusts;
trusts = ApplicationSecurityManager.UserApplicationTrusts;
foreach (ApplicationTrust trust in trusts)
{
Console.WriteLine(trust.ApplicationIdentity.FullName);
}

D.
ApplicationTrustCollection trusts;
trusts = ApplicationSecurityManager.UserApplicationTrusts;
foreach (object trust in trusts)
{
Console.WriteLine(trust.ToString());
}



Leave a Reply 1

Your email address will not be published. Required fields are marked *


networkmanagers

networkmanagers

Correct answer is C