ASP.NET


ASP.NET Settings Schema (The System.Web Element) tutorials
-
This element specifies the configuration elements and configuration section that configure ASP.NET Web applications and control how the application behaves.
Syntax:
The syntax of the system.web element is such as:
<system.web>
<anonymousIdentification> <authentication> <authorization>
<caching> <clientTarget> <hostingEnvironment>
<httpCookies> <httpModules>
<httpRuntime> <identity> <machineKey> <pages>
<profile> <roleManager> <securityPolicy>
<sessionPageState> <sessionState> <siteMap> <trace>
<urlMappings> <webControls> <webParts>
<webServices> <xhtmlConformance>
</system.web>
The descriptions of the above elements are such as.
-
authentication Element: It configures the ASP.NET authentication support.
Syntax:
<authentication
mode="[Windows|Forms|Passport|None]" >
<forms>...</forms>
<passport/>
</authentication>
-
anonymousIdentification Element: This element Configures anonymous identification for application authorization. This is required to identify entities that are not authenticated when authorization is required.
Syntax
<anonymousIdentification
enabled="[true | false]"
cookieless="[UseUri | UseCookies | AutoDetect | UseDeviceProfile]"
cookieName=""
cookiePath=""
< cookieProtection="[None | Validation | Encryption | All]"
cookieRequireSSL="[true | false]"
cookieSlidingExpiration="[true | false]"
cookieTimeout="[DD.HH:MM:SS]"
domain="cookie domain"
/>
-
authorization Element: This element configures the authorization for a web application controlling client access to URL resources.
Syntax:
<authorization>
<allow .../>
<deny .../>
</authorization>
-
caching Element: This Element Configures the cache settings for a Web application
Syntax:
<caching>
<cache>...</cache>
<outputCache>...</outputCache>
<outputCacheSettings>...</outputCacheSettings>
<sqlCacheDependency>...</sqlCacheDependency>
<</caching>
-
hostingEnvironment Element: Defines configuration settings that control the behavior of the application hosting environment.
Syntax:
<hostingEnvironment idleTimeout="HH:MM:SS"
shadowCopyBinAssemblies="true|false"
shutdownTimeout="number"/>
-
httpCookies Element: This element configures a Web application cookies property:
Syntax:
<httpCookies domain="String"
httpOnlyCookies="true|false"
requireSSL="true|false" />
-
httpModules Element:This elements configures the HTTP modules within an application.it can be declaired at any level of hierarchy.
Syntax:
<httpModules>
<add... />
<remove... />
<clear/>
</httpModules>
-
httpRuntime Element:This elements configures the ASP.NET HTTP run-time settings that determine how to process a request for an ASP.NET application.
Syntax:
<httpRuntime
executionTimeout = "HH:MM:SS" maxRequestLength = "number"
requestLengthDiskThreshold = "number"
useFullyQualifiedRedirectUrl = "[True|False]" minFreeThreads = "number"
minLocalRequestFreeThreads = "number"
appRequestQueueLimit = "number" enableKernelOutputCache = "[True|False]"
enableVersionHeader = "[True|False]"
apartmentThreading = "[True|False]"
requireRootedSaveAsPath = "[True|False]" enable = "[True|False]"
sendCacheControlHeader = "[True|False]"
shutdownTimeout = "HH:MM:SS"
delayNotificationTimeout = "HH:MM:SS"
waitChangeNotification = "number"
maxWaitChangeNotification = "number"
enableHeaderChecking = "[True|False]"
/>
-
identity Element: This element configures the identity of the Web application.it can be declared at any level in the configuration file hierarchy.
Syntax:
<identity impersonate="true|false"
userName="domain\username"
password="password"/>
-
machineKey Element: This element configures keys for encryption and decryption of forms authentication cookie data and view-state data etc.
Syntax:
<machineKey
validationKey="AutoGenerate,IsolateApps" [String]
decryptionKey="AutoGenerate,IsolateApps" [String]
validation="SHA1" [SHA1 | MD5 | 3DES | AES]
decryption="Auto" [Auto | DES | 3DES | AES]
/>
Where:
DES: Data Encryption Standard
3DES: Tripple DES algorithm to decrypt data
AES: default algorithm to decrypt data.
-
pages Element: This element defines page-specific configuration settings globally.
Syntax:
<pages
buffer="[True|False]" enableEventValidation="[True|False]"
enableSessionState="[True|False|ReadOnly]"
enableViewState="[True|False]"
enableViewStateMac="[True|False]" smartNavigation="[True|False]"
autoEventWireup="[True|False]" pageBaseType="typename, assembly"
userControlBaseType="typename"
validateRequest="[True|False]" masterPageFile="file path"
theme="string" styleSheetTheme="string" maxPageStateFieldLength="number"
compilationMode="[Always|Auto|Never]" pageParserFilterType="string"
viewStateEncryptionMode="[Always|Auto|Never]"
maintainScrollPositionOnPostBack="[True|False]" asyncTimeout="number" >
<controls>...</controls>
<namespaces>...</namespaces>
<tagMapping>...</tagMapping>
</pages>
-
profile Element: profile elements configures parameters for managing user profile values by using the ASP.NET profile, added in the .NET Framework version 2.0.
Syntax:
<profile
enabled="true|false"
inherits="fully qualified type reference"
automaticSaveEnabled="true|false"
defaultProvider="provider name">
<properties>...</properties>
<providers>...</providers>
</profile>
-
roleManager Element: roleManager configurs an application for role management.
Syntax:
<roleManager
cacheRolesInCookie="true|false"
cookieName="name"
cookiePath="/"
cookieProtection="All|Encryption|Validation|None"
cookieRequireSSL="true|false "
cookieSlidingExpiration="true|false "
cookieTimeout="number of minutes"
createPersistentCookie="true|false"
defaultProvider="provider name"
domain="cookie domain">
enabled="true|false"
maxCachedResults="maximum number of role names cached"
<providers>...</providers>
</roleManager>
-
securityPolicy Element: securityPolicy elements defines a collection of mappings between security policy files and the trust level names for the security polisy files.
Syntax:
<securityPolicy>
<trustLevel />
</securityPolicy>
-
sessionPageState:sessionPageState element configures the settings page view-state for an ASP.NET application.
Syntax:
<sessionPageState historySize="number" />
-
sessionStateElement: The <sessionState> section provides a means to configure the session state HttpModule of the ASP.NET application.
Syntax:
<sessionstate
mode = "mode="Off|Inproc|StateServer|SqlServer"
cookieless="true|false"
timeout="number of minutes"
connectionString="server name:port number"
sqlConnectionString="sql connection string"/>
-
siteMap Element: This element specifies the configuration settings to support the navigation infrastructure for configuring storing, and rendering site navigation.
-
traceElement: The trace element allows the configuration of the ASP.NET trace service.
-
urlMapping Element: This element specifies a mapping that hides the real URL and maps it to a more user-friendly URL.
Syntax:
<urlMappings enabled="true | false">
<add.../>
<clear />
<remove.../>
</urlMappings>
-
webControls Element: Specifies the shared location of the client script files
Syntax:
<webControls clientScriptsLocation="String" />
-
webParts Element: Specifies a Web Parts personalization provider, sets personalization authorizations, and adds custom classes that extend the WebPartTransformer class for use by Web Parts connections.
Syntax:
<webParts enableExport="true|false">
<personalization...>...</personalization>
<transformers>...</transformers >
</webParts>
-
webServices Element: This element controls the behavior of ASP.NET Web services and their clients. By default, the webServices element and its descendants are applied to any Web service or proxy class to which the configuration applies.
Syntax:
<webServices>
<protocols>
<add name="protocol name"/> <remove name="protocol name"/> <clear/> </protocols>
<serviceDescriptionFormatExtensionTypes>
<add type="type"/> <remove type="type"/> <clear/>
</serviceDescriptionFormatExtensionTypes>
<soapExtensionTypes>
<add type="type" priority="number" group="0|1"/>/> <remove type="type"/> <clear/>
</soapExtensionTypes> <soapExtensionReflectorTypes>
<add type="type" priority="number" group="0|1"/>/> <remove type="type"/> <clear/>
</soapExtensionReflectorTypes>
<soapExtensionImporterTypes>
<add type="type" priority="number" group="0|1"/>/> <remove type="type"/> <clear/>
</soapExtensionImporterTypes>
<wsdlHelpGenerator href="help generator file"/> <diagnostics suppressReturningExceptions="true|false" />
</webServices>