Question 31
You are developing an ASP.NET MVC application by using Visual Studio.
The application throws and handles exceptions when it runs.
You need to examine the state of the application when exceptions are thrown.
What should you do?
Question 32
You are developing an ASP.NET MVC application that authenticates a user by using claims-based
authentication.
The application must:
-Use Windows Identity Foundation 4.5.
-Support the Windows Azure Access Control Service.
You need to implement authentication. How should you build the class constructor? (To answer, select the appropriate option from the drop-down list in the answer area.)
Hot Area:
Question 33
You are developing an ASP.NET Core Web API.
API methods must use JSON Web Tokens (JWT) to authenticate the method caller.
You need to implement JWT authentication.
How should you complete the code? To answer, select the appropriate options in the answer area.
NOTE: Each correct selection is worth one point.
Question 34
You are developing an ASP.NET Core MVC web application that uses custom security middleware. The middleware will add a response header to stop pages form loading when reflected cross-site scripting (XSS) attacks are detected.
The security middleware component must be constructed once per application lifetime.
You need to implement the middleware.
How should you complete the code? To answer, select the appropriate options in the answer area.
NOTE: Each correct selection is worth one point.
Question 35
You are developing an ASP.NET MVC web application that includes the following method.
You need to test the GoldMined method.
Which unit test should you use?






