What should you recommend?
You are designing an ASP.NET Web application that will be deployed both to a server that runs IIS 6 and to a server that runs IIS 7.0.
The Web application must meet the following requirements:
– Log all unhandled exceptions.
– Write exception details to a custom error log.
– When an exception occurs, write the user credentials to a custom error log.
You need to recommend an approach for handling errors.
What should you recommend?
What should you do next?
You develop a Windows Communication Foundation (WCF) service that uses basic authentication for client credentials.
This service is currently configured to use message security. The service is hosted on a server in workgroup mode.
Users report that their passwords are stolen when they use public computers.
You need to ensure that messages are secure and users are authenticated.
You prevent the service from being called over HTTP through Microsoft Internet Information Services (IIS) configuration.
What should you do next?
What should you do?
You use Microsoft Visual Studio 2010 and Microsoft .NET Framework 4.0 to create an application.
The application connects to several SQL Server databases. You create a function that modifies customer records that are stored in multiple databases.
All updates for a given record are performed in a single transaction. You need to ensure that all transactions can be recovered.
What should you do?
What should you recommend?
You are reviewing an ASP.NET Web application that uses dynamic SQL.
The Web application validates user credentials against a Microsoft SQL Server 2008 database by using Forms authentication and hashing the password.
You need to recommend an approach for testing whether users can gain elevated access to the Web application.
What should you recommend?
Which code segment should you insert at line 07?
You are developing a Windows Communication Foundation (WCF) service to provide an in-memory cache for many Web applications.
The service contract is defined as follows. (Line numbers are included for reference only.)
01 [ServiceContract]
02 public interface IDataCache
03 {
04 …
05 }
06
07
08 public class DataCache : IDataCache
09 {
10 …
11 }
You need to ensure that all users share the cache. Which code segment should you insert at line 07?
What should you do?
You use Microsoft Visual Studio 2010 and Microsoft .NET Framework 4.0 to create an application.
The application updates several Microsoft SQL Server databases within a single transaction.
You need to ensure that after a resource failure, you can manage unresolved transactions. What should you do?
What should you recommend?
You are designing an ASP.NET Web application.
A page of the Web application will allow users to post comments and view comments posted by other users.
You need to recommend an approach for preventing the Web application from storing malicious content.
What should you recommend?
What should you do in the Windows Service class?
You are developing a Windows Service. The Windows Service will host a Windows Communication Foundation (WCF) service.
The Windows Service class will inherit from ServiceBase.
You need to ensure that the WCF service starts when the Windows Service is restarted. What should you do in the Windows Service class?
What should you do?
You use Microsoft Visual Studio 2010 and Microsoft .NET Framework 4.0 to create an application.
The application uses the ADO.NET Entity Framework to model entities.
You need to ensure that the model and mapping files are not deployed as application resources. What should you do?
What should you recommend?
You are designing an ASP.NET Web application.
The Web application must allow users to authenticate by using LDAP on a Web form.
You need to recommend an authentication model.
What should you recommend?