Exam 70-536 : .NET Framework Application Development Foundation Part – 12

Question: You create a method that runs by using the credentials of the end user. You need to use Microsoft Windows groups to authorize the user. You must add a code segment that identifies whether a user is in the local group named Clerk. Which code segment should you use?

Correct Answer: 2


Question: You are writing code for user authentication and authorization. The username, password, and roles are stored in your application data store. You need to establish a user security context that will be used for authorization checks such as IsInRole. You write the following code segment to authorize the user.

You need to complete this code so that it establishes the user security context. Which code segment should you use?

Correct Answer: 1


Question: You are developing a method to call a COM component. You need to use declarative security to explicitly request the runtime to perform a full stack walk. You must ensure that all callers have the required level of trust for COM interop before the callers execute your method. Which attribute should you place on the method?

  1. [SecurityPermission(SecurityAction.Demand,
    Flags=SecurityPermissionFlag.UnmanagedCode)]
  2. [SecurityPermission(SecurityAction.LinkDemand,
    Flags=SecurityPermissionFlag.UnmanagedCode)]
  3. [SecurityPermission(SecurityAction.Assert,
    Flags = SecurityPermissionFlag.UnmanagedCode)]
  4. [SecurityPermission(SecurityAction.Deny,
    Flags = SecurityPermissionFlag.UnmanagedCode)]

Correct Answer: 1


Question: You create an application to send a message by e-mail. An SMTP server is available on the local subnet. The SMTP server is named smtp.Company.com. To test the application, you use a source address, me@Company.com, and a target address, you@Company.com. You need to transmit the e-mail message. Which code segment should you use?

Correct Answer: 3


Question: You need to write a code segment that will create a common language runtime (CLR) unit of isolation within an application. Which code segment should you use?

Correct Answer: 3

Tagged . Bookmark the permalink.

Leave a Reply

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

This site uses Akismet to reduce spam. Learn how your comment data is processed.