Code:
/ FXUpdate3074 / FXUpdate3074 / 1.1 / DEVDIV / depot / DevDiv / releases / whidbey / QFE / ndp / fx / src / xsp / System / Web / Configuration / SecurityPolicySection.cs / 3 / SecurityPolicySection.cs
//------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // //----------------------------------------------------------------------------- namespace System.Web.Configuration { using System; using System.Xml; using System.Configuration; using System.Collections.Specialized; using System.Collections; using System.IO; using System.Text; using System.ComponentModel; using System.Security.Permissions; /* This data is in a location in Machine.Config... How do I deal with that? For now I will leave the section in machine.config, The initialization of the trust levels are overwritable in this collection.*/ [AspNetHostingPermission(SecurityAction.LinkDemand, Level=AspNetHostingPermissionLevel.Minimal)] public sealed class SecurityPolicySection : ConfigurationSection { private static ConfigurationPropertyCollection _properties; private static readonly ConfigurationProperty _propTrustLevels = new ConfigurationProperty(null, typeof(TrustLevelCollection), null, ConfigurationPropertyOptions.IsDefaultCollection); static SecurityPolicySection() { // Property initialization _properties = new ConfigurationPropertyCollection(); _properties.Add(_propTrustLevels); } public SecurityPolicySection() { } protected override ConfigurationPropertyCollection Properties { get { return _properties; } } [ConfigurationProperty("", IsDefaultCollection = true)] public TrustLevelCollection TrustLevels { get { return (TrustLevelCollection)base[_propTrustLevels]; } } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. // Copyright (c) Microsoft Corporation. All rights reserved. //------------------------------------------------------------------------------ // // Copyright (c) Microsoft Corporation. All rights reserved. // //----------------------------------------------------------------------------- namespace System.Web.Configuration { using System; using System.Xml; using System.Configuration; using System.Collections.Specialized; using System.Collections; using System.IO; using System.Text; using System.ComponentModel; using System.Security.Permissions; /* This data is in a location in Machine.Config... How do I deal with that? For now I will leave the section in machine.config, The initialization of the trust levels are overwritable in this collection.*/ [AspNetHostingPermission(SecurityAction.LinkDemand, Level=AspNetHostingPermissionLevel.Minimal)] public sealed class SecurityPolicySection : ConfigurationSection { private static ConfigurationPropertyCollection _properties; private static readonly ConfigurationProperty _propTrustLevels = new ConfigurationProperty(null, typeof(TrustLevelCollection), null, ConfigurationPropertyOptions.IsDefaultCollection); static SecurityPolicySection() { // Property initialization _properties = new ConfigurationPropertyCollection(); _properties.Add(_propTrustLevels); } public SecurityPolicySection() { } protected override ConfigurationPropertyCollection Properties { get { return _properties; } } [ConfigurationProperty("", IsDefaultCollection = true)] public TrustLevelCollection TrustLevels { get { return (TrustLevelCollection)base[_propTrustLevels]; } } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. // Copyright (c) Microsoft Corporation. All rights reserved.
Link Menu
This book is available now!
Buy at Amazon US or
Buy at Amazon UK
- ModelTreeEnumerator.cs
- CodeCatchClause.cs
- _NestedMultipleAsyncResult.cs
- InvalidCastException.cs
- PropertyBuilder.cs
- HttpApplicationFactory.cs
- SmiEventStream.cs
- NamedObject.cs
- EditingMode.cs
- MouseEvent.cs
- AnnotationDocumentPaginator.cs
- UserControlAutomationPeer.cs
- TreeNodeEventArgs.cs
- CrossAppDomainChannel.cs
- SecurityTokenTypes.cs
- XmlEncodedRawTextWriter.cs
- GradientStop.cs
- Set.cs
- SerializationFieldInfo.cs
- CurrencyWrapper.cs
- SortedSet.cs
- BamlResourceDeserializer.cs
- SimpleBitVector32.cs
- XmlDeclaration.cs
- TypeElement.cs
- UIElement3D.cs
- RegisteredExpandoAttribute.cs
- TreeNodeEventArgs.cs
- PointLightBase.cs
- DesignDataSource.cs
- ProcessThreadDesigner.cs
- _UncName.cs
- DoubleSumAggregationOperator.cs
- MobileControlPersister.cs
- ValueHandle.cs
- DataServiceQuery.cs
- BindToObject.cs
- Encoder.cs
- WebPartDescription.cs
- NavigationHelper.cs
- QueryModel.cs
- TrustManager.cs
- Int16KeyFrameCollection.cs
- AstTree.cs
- ParameterCollection.cs
- Timer.cs
- TransactionFilter.cs
- EditorBrowsableAttribute.cs
- RealProxy.cs
- Size3DValueSerializer.cs
- SafeProcessHandle.cs
- PointF.cs
- ResourceReferenceKeyNotFoundException.cs
- ResourceDescriptionAttribute.cs
- InvokeMemberBinder.cs
- DockingAttribute.cs
- _IPv6Address.cs
- SqlDataSourceQueryEditor.cs
- SerializationEventsCache.cs
- IApplicationTrustManager.cs
- ApplicationActivator.cs
- RequestTimeoutManager.cs
- TemplateApplicationHelper.cs
- OrderedEnumerableRowCollection.cs
- MessageHeaderDescriptionCollection.cs
- clipboard.cs
- WmlValidatorAdapter.cs
- UIHelper.cs
- WebPartEditorApplyVerb.cs
- CommandDevice.cs
- EntityStoreSchemaFilterEntry.cs
- XmlRootAttribute.cs
- HttpListenerException.cs
- PrintDialog.cs
- ConnectionsZone.cs
- ExpressionConverter.cs
- MenuScrollingVisibilityConverter.cs
- CodeDOMUtility.cs
- AnimatedTypeHelpers.cs
- VirtualPathProvider.cs
- ContractReference.cs
- WebPartCloseVerb.cs
- InputProcessorProfiles.cs
- UxThemeWrapper.cs
- JournalNavigationScope.cs
- PropertyDescriptorComparer.cs
- PersonalizableTypeEntry.cs
- safex509handles.cs
- EventWaitHandleSecurity.cs
- ProjectionPlan.cs
- AsnEncodedData.cs
- ScriptMethodAttribute.cs
- UIElement3D.cs
- OutputCacheProfileCollection.cs
- SchemaAttDef.cs
- FixedSOMElement.cs
- QueuePathEditor.cs
- GeneralTransform.cs
- FtpWebResponse.cs
- IsolatedStorageFileStream.cs