Code:
/ 4.0 / 4.0 / untmp / DEVDIV_TFS / Dev10 / Releases / RTMRel / ndp / fx / src / xsp / System / Web / Configuration / AuthorizationSection.cs / 1305376 / AuthorizationSection.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.Globalization; using System.IO; using System.Text; using System.Security.Principal; using System.Web.Util; using System.ComponentModel; using System.Security.Permissions; /**/ /// /// public sealed class AuthorizationSection : ConfigurationSection { private static ConfigurationPropertyCollection _properties; private static readonly ConfigurationProperty _propRules = new ConfigurationProperty(null, typeof(AuthorizationRuleCollection), null, ConfigurationPropertyOptions.IsDefaultCollection); private bool _EveryoneAllowed = false; internal bool EveryoneAllowed { get { return _EveryoneAllowed; } } static AuthorizationSection() { // Property initialization _properties = new ConfigurationPropertyCollection(); _properties.Add(_propRules); } public AuthorizationSection() { } protected override ConfigurationPropertyCollection Properties { get { return _properties; } } [ConfigurationProperty("", IsDefaultCollection = true)] public AuthorizationRuleCollection Rules { get { return (AuthorizationRuleCollection)base[_propRules]; } } protected override void PostDeserialize() { if (Rules.Count > 0) { _EveryoneAllowed = (Rules[0].Action == AuthorizationRuleAction.Allow && Rules[0].Everyone); } } internal bool IsUserAllowed(IPrincipal user, String verb) { return Rules.IsUserAllowed(user, verb); } } // class AuthorizationSection } // File provided for Reference Use Only by Microsoft Corporation (c) 2007.Adds Authorization specific information to this section. /// ///
Link Menu
This book is available now!
Buy at Amazon US or
Buy at Amazon UK
- InheritanceAttribute.cs
- LabelLiteral.cs
- ApplicationSecurityManager.cs
- UnmanagedHandle.cs
- XmlLanguage.cs
- FormViewPageEventArgs.cs
- DBCSCodePageEncoding.cs
- PeerToPeerException.cs
- DebugHandleTracker.cs
- _NetRes.cs
- SspiSafeHandles.cs
- ParsedAttributeCollection.cs
- SimpleType.cs
- Pkcs9Attribute.cs
- AutomationElement.cs
- TextEditorDragDrop.cs
- ToolStripDropDown.cs
- TextContainerChangedEventArgs.cs
- VisualStateManager.cs
- COM2ExtendedBrowsingHandler.cs
- SettingsContext.cs
- TrustLevel.cs
- FormView.cs
- PreservationFileWriter.cs
- RectAnimationUsingKeyFrames.cs
- LessThan.cs
- DataBindingCollection.cs
- IgnorePropertiesAttribute.cs
- TemplateInstanceAttribute.cs
- HopperCache.cs
- CodeExpressionRuleDeclaration.cs
- GeneratedContractType.cs
- DSASignatureFormatter.cs
- SoapIncludeAttribute.cs
- WebBrowserEvent.cs
- WinEventWrap.cs
- DataGridViewCellToolTipTextNeededEventArgs.cs
- CommonDialog.cs
- Setter.cs
- codemethodreferenceexpression.cs
- HyperLink.cs
- TemplateContainer.cs
- CompilationLock.cs
- XmlNamedNodeMap.cs
- Variant.cs
- Events.cs
- NonVisualControlAttribute.cs
- WebDescriptionAttribute.cs
- IPPacketInformation.cs
- HtmlInputHidden.cs
- IApplicationTrustManager.cs
- RoutedEventArgs.cs
- InputProviderSite.cs
- RadioButton.cs
- DesignerTransaction.cs
- WebPartConnection.cs
- UInt16Converter.cs
- DataServiceExpressionVisitor.cs
- KeyGesture.cs
- TaskExtensions.cs
- SymmetricKey.cs
- CommonRemoteMemoryBlock.cs
- XmlHierarchicalEnumerable.cs
- InputScopeAttribute.cs
- EntityDataSourceValidationException.cs
- SessionStateUtil.cs
- PersonalizationStateInfoCollection.cs
- DataReceivedEventArgs.cs
- Rotation3DAnimation.cs
- JsonByteArrayDataContract.cs
- CaseCqlBlock.cs
- MemberAccessException.cs
- DataViewManagerListItemTypeDescriptor.cs
- ColumnWidthChangingEvent.cs
- LineBreakRecord.cs
- AutoCompleteStringCollection.cs
- updatecommandorderer.cs
- CompressionTransform.cs
- RectAnimationClockResource.cs
- DataGridrowEditEndingEventArgs.cs
- HttpWebRequest.cs
- TraceContextEventArgs.cs
- _ProxyRegBlob.cs
- TraceSection.cs
- DeadCharTextComposition.cs
- DetailsViewPagerRow.cs
- CharEnumerator.cs
- WebServiceParameterData.cs
- TransactionProtocol.cs
- InfoCardRSACryptoProvider.cs
- ListItemConverter.cs
- VBCodeProvider.cs
- PartialCachingControl.cs
- TextFormatterContext.cs
- ISCIIEncoding.cs
- CodeNamespace.cs
- TextMarkerSource.cs
- AppDomainProtocolHandler.cs
- CheckBoxPopupAdapter.cs
- PathFigure.cs