11.07.2015 Views

Improving Web Application Security: Threats and - CGISecurity

Improving Web Application Security: Threats and - CGISecurity

Improving Web Application Security: Threats and - CGISecurity

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

662 Part V: Assessing Your <strong>Security</strong>The sessionState element configures user session state management for yourapplication. Review the following questions:● Do you use a remote state store?Check the state store by examining the mode attribute.If you use a remote state store <strong>and</strong> the mode attribute is set to stateServer orSQLServer, check the stateConnectionString <strong>and</strong> sqlConnectionString attributesrespectively. So that credentials are not included in the database connection string,make sure the connection strings are secured in encrypted format in the registryusing the Aspnet_setreg.exe tool, or that Windows authentication is used toconnect to the SQL Server state store.The following configuration shows what the stateConnectionString looks likewhen Aspnet_setreg.exe has been used to encrypt the string in the registry.●Do you use Windows authentication to the state database?If you use the SQL Server state store, check to see if you use Windowsauthentication to connect to the state database. This means that credentials are notstored in the connection string <strong>and</strong> that credentials are not transmitted over thewire.If you must use SQL authentication, make sure the connection string is encryptedin the registry <strong>and</strong> that a server certificate is installed on the database server toensure that credentials are encrypted over the wire.This element lists the HTTP h<strong>and</strong>lers that process requests for specific file types.Check to ensure that you have disabled all unused file types.Map unused file types to System.<strong>Web</strong>.HttpForbiddenH<strong>and</strong>ler to prevent their HTTPretrieval. For example, if your application does not use <strong>Web</strong> services, map the .asmxextension as follows:

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!