Code:
/ 4.0 / 4.0 / untmp / DEVDIV_TFS / Dev10 / Releases / RTMRel / ndp / cdf / src / WCF / IdentityModel / System / IdentityModel / Selectors / WindowsSecurityTokenAuthenticator.cs / 1305376 / WindowsSecurityTokenAuthenticator.cs
//------------------------------------------------------------ // Copyright (c) Microsoft Corporation. All rights reserved. //----------------------------------------------------------- namespace System.IdentityModel.Selectors { using System.Collections.Generic; using System.Collections.ObjectModel; using System.IdentityModel.Claims; using System.IdentityModel.Policy; using System.IdentityModel.Tokens; public class WindowsSecurityTokenAuthenticator : SecurityTokenAuthenticator { bool includeWindowsGroups; public WindowsSecurityTokenAuthenticator() : this(WindowsClaimSet.DefaultIncludeWindowsGroups) { } public WindowsSecurityTokenAuthenticator(bool includeWindowsGroups) { this.includeWindowsGroups = includeWindowsGroups; } protected override bool CanValidateTokenCore(SecurityToken token) { return token is WindowsSecurityToken; } protected override ReadOnlyCollectionValidateTokenCore(SecurityToken token) { WindowsSecurityToken windowsToken = (WindowsSecurityToken)token; WindowsClaimSet claimSet = new WindowsClaimSet(windowsToken.WindowsIdentity, windowsToken.AuthenticationType, this.includeWindowsGroups, windowsToken.ValidTo); return SecurityUtils.CreateAuthorizationPolicies(claimSet, windowsToken.ValidTo); } } } // 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
- TableCell.cs
- TextTreeInsertElementUndoUnit.cs
- ChangeInterceptorAttribute.cs
- FakeModelItemImpl.cs
- Comparer.cs
- SoapSchemaImporter.cs
- FunctionParameter.cs
- COM2IVsPerPropertyBrowsingHandler.cs
- QilFunction.cs
- ResourceReferenceKeyNotFoundException.cs
- PlanCompilerUtil.cs
- EntitySetBaseCollection.cs
- MimeTypePropertyAttribute.cs
- TimeSpanMinutesConverter.cs
- WebResourceAttribute.cs
- PersonalizationProviderHelper.cs
- SafeRightsManagementSessionHandle.cs
- UnicodeEncoding.cs
- BaseTemplateCodeDomTreeGenerator.cs
- DynamicRendererThreadManager.cs
- UserNameSecurityTokenAuthenticator.cs
- RegexCompiler.cs
- XsltSettings.cs
- SecurityDescriptor.cs
- ApplicationServiceHelper.cs
- ExtentKey.cs
- SafeCryptoHandles.cs
- Ray3DHitTestResult.cs
- CreateParams.cs
- IPAddress.cs
- assertwrapper.cs
- xmlsaver.cs
- ThemeInfoAttribute.cs
- XPathScanner.cs
- ResourceContainer.cs
- WrappedIUnknown.cs
- ByteAnimation.cs
- TransformProviderWrapper.cs
- XmlObjectSerializerWriteContextComplex.cs
- ToolboxItem.cs
- StringCollectionMarkupSerializer.cs
- ProjectedSlot.cs
- ActivationArguments.cs
- RectIndependentAnimationStorage.cs
- SerializationException.cs
- MemoryMappedFileSecurity.cs
- VBIdentifierTrimConverter.cs
- Connector.xaml.cs
- WmpBitmapEncoder.cs
- MulticastOption.cs
- WindowsProgressbar.cs
- TextRange.cs
- Scene3D.cs
- Page.cs
- MessageSmuggler.cs
- ThreadStateException.cs
- WorkflowQueuingService.cs
- SystemColors.cs
- TimeoutValidationAttribute.cs
- RegexReplacement.cs
- GridViewUpdatedEventArgs.cs
- ControlBindingsCollection.cs
- Transform3DGroup.cs
- MsmqIntegrationBinding.cs
- ComplexLine.cs
- SchemaHelper.cs
- ToolStripProfessionalLowResolutionRenderer.cs
- DesignerDataStoredProcedure.cs
- UserInitiatedRoutedEventPermissionAttribute.cs
- CmsInterop.cs
- XmlTextReader.cs
- PersonalizationProvider.cs
- log.cs
- AxisAngleRotation3D.cs
- SoapHeaders.cs
- BitmapEffectInputConnector.cs
- RepeatButtonAutomationPeer.cs
- StringWriter.cs
- StreamGeometryContext.cs
- DispatchChannelSink.cs
- ObjectListCommandEventArgs.cs
- CharAnimationBase.cs
- DivideByZeroException.cs
- DataRow.cs
- VisualStyleInformation.cs
- XmlElementElementCollection.cs
- UnknownBitmapEncoder.cs
- ListBoxChrome.cs
- X509Utils.cs
- SharedUtils.cs
- InputProcessorProfilesLoader.cs
- FreezableCollection.cs
- BindingValueChangedEventArgs.cs
- OdbcDataReader.cs
- DbUpdateCommandTree.cs
- MenuItemBindingCollection.cs
- CheckBox.cs
- AstTree.cs
- BitmapScalingModeValidation.cs
- XmlSiteMapProvider.cs