Code:
/ Net / Net / 3.5.50727.3053 / DEVDIV / depot / DevDiv / releases / whidbey / netfxsp / ndp / fx / src / xsp / System / Web / Configuration / SecurityPolicySection.cs / 5 / 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. // //----------------------------------------------------------------------------- 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.
Link Menu
This book is available now!
Buy at Amazon US or
Buy at Amazon UK
- WebBrowserUriTypeConverter.cs
- _ConnectionGroup.cs
- RadialGradientBrush.cs
- EventToken.cs
- DrawingGroup.cs
- GlobalizationAssembly.cs
- _ListenerResponseStream.cs
- ClientConfigurationHost.cs
- HttpRawResponse.cs
- WindowsIPAddress.cs
- SchemaTypeEmitter.cs
- StatusBarDrawItemEvent.cs
- SequenceDesigner.cs
- ExtractedStateEntry.cs
- FilterableAttribute.cs
- ReflectPropertyDescriptor.cs
- WebPartConnectionsConfigureVerb.cs
- BaseUriHelper.cs
- XmlCollation.cs
- EntityDataSourceConfigureObjectContext.cs
- SmtpMail.cs
- WindowsFormsLinkLabel.cs
- PrintDocument.cs
- GPRECTF.cs
- IpcClientManager.cs
- CoTaskMemSafeHandle.cs
- QilStrConcatenator.cs
- CounterCreationDataCollection.cs
- IDictionary.cs
- ContainerVisual.cs
- AsymmetricSignatureFormatter.cs
- SessionIDManager.cs
- ShimAsPublicXamlType.cs
- PropertyToken.cs
- SQLDecimal.cs
- ResolveNameEventArgs.cs
- DataServiceContext.cs
- TemplateControlBuildProvider.cs
- StreamDocument.cs
- SQLMoney.cs
- sortedlist.cs
- GeometryDrawing.cs
- Annotation.cs
- HtmlInputPassword.cs
- AncillaryOps.cs
- ConstraintEnumerator.cs
- EditingCoordinator.cs
- FontEmbeddingManager.cs
- ExtractorMetadata.cs
- ConfigurationStrings.cs
- ImageSource.cs
- SQLByte.cs
- TimeoutConverter.cs
- NullNotAllowedCollection.cs
- Internal.cs
- Ref.cs
- ThicknessAnimationUsingKeyFrames.cs
- BitmapVisualManager.cs
- StringAnimationUsingKeyFrames.cs
- InternalBase.cs
- MediaElementAutomationPeer.cs
- tooltip.cs
- MetadataExchangeBindings.cs
- PropertyGridView.cs
- StorageBasedPackageProperties.cs
- ActivationWorker.cs
- DomainConstraint.cs
- TimeIntervalCollection.cs
- MetadataArtifactLoader.cs
- SourceFileBuildProvider.cs
- HttpSocketManager.cs
- IISMapPath.cs
- FrameworkElementFactoryMarkupObject.cs
- MarkupCompilePass1.cs
- DataBindingList.cs
- IImplicitResourceProvider.cs
- UnsafeNetInfoNativeMethods.cs
- XmlAggregates.cs
- HttpProfileGroupBase.cs
- ConnectionManagementSection.cs
- FileSystemWatcher.cs
- TrackingStringDictionary.cs
- XmlParser.cs
- ProcessModelSection.cs
- SEHException.cs
- QilReference.cs
- LinkedList.cs
- ShowExpandedMultiValueConverter.cs
- StylusDownEventArgs.cs
- SchemaNames.cs
- ParameterToken.cs
- FileRecordSequenceCompletedAsyncResult.cs
- TypeReference.cs
- AssemblyLoader.cs
- UriScheme.cs
- ColorTranslator.cs
- CreateUserWizard.cs
- EnumerableRowCollectionExtensions.cs
- ButtonChrome.cs
- HttpCacheVaryByContentEncodings.cs