Code:
/ WCF / WCF / 3.5.30729.1 / untmp / Orcas / SP / ndp / cdf / src / WCF / ServiceModel / System / ServiceModel / Security / SspiSecurityTokenProvider.cs / 1 / SspiSecurityTokenProvider.cs
//------------------------------------------------------------------------------
// Copyright (c) Microsoft Corporation. All rights reserved.
//-----------------------------------------------------------------------------
namespace System.ServiceModel.Security
{
using System.IdentityModel.Claims;
using System.ServiceModel;
using System.IdentityModel.Policy;
using System.IdentityModel.Selectors;
using System.IdentityModel.Tokens;
using System.ServiceModel.Security.Tokens;
using System.Net;
using System.Security.Principal;
public class SspiSecurityTokenProvider : SecurityTokenProvider
{
internal const bool DefaultAllowNtlm = true;
internal const bool DefaultExtractWindowsGroupClaims = true;
internal const bool DefaultAllowUnauthenticatedCallers = false;
SspiSecurityToken token;
// client side ctor
public SspiSecurityTokenProvider(NetworkCredential credential, bool allowNtlm, TokenImpersonationLevel impersonationLevel)
{
this.token = new SspiSecurityToken(impersonationLevel, allowNtlm, credential);
}
// service side ctor
public SspiSecurityTokenProvider(NetworkCredential credential, bool extractGroupsForWindowsAccounts, bool allowUnauthenticatedCallers)
{
this.token = new SspiSecurityToken(credential, extractGroupsForWindowsAccounts, allowUnauthenticatedCallers);
}
protected override SecurityToken GetTokenCore(TimeSpan timeout)
{
return this.token;
}
}
}
// 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
- SessionStateContainer.cs
- Trace.cs
- XsltInput.cs
- BuildResultCache.cs
- ObjectDataSourceEventArgs.cs
- OutputScopeManager.cs
- ImageAttributes.cs
- Hyperlink.cs
- Monitor.cs
- RolePrincipal.cs
- DbDataReader.cs
- WizardPanel.cs
- GetMemberBinder.cs
- DiffuseMaterial.cs
- WmlCalendarAdapter.cs
- ServicePointManager.cs
- HttpCookiesSection.cs
- PropertyValueChangedEvent.cs
- ToolboxCategory.cs
- XmlSchemaAttributeGroup.cs
- Timer.cs
- TraceData.cs
- SetterBase.cs
- CacheEntry.cs
- columnmapkeybuilder.cs
- DesignerObjectListAdapter.cs
- ObjectConverter.cs
- DataShape.cs
- MessageQueue.cs
- _Semaphore.cs
- DynamicMethod.cs
- HttpServerVarsCollection.cs
- VisualBasicSettingsConverter.cs
- DictionaryEntry.cs
- IntegerValidator.cs
- IISUnsafeMethods.cs
- PageThemeCodeDomTreeGenerator.cs
- ImageSourceValueSerializer.cs
- Stylesheet.cs
- AssertFilter.cs
- ProtocolsSection.cs
- TransformGroup.cs
- DocumentEventArgs.cs
- BinaryConverter.cs
- ListViewHitTestInfo.cs
- WebServiceTypeData.cs
- TransformGroup.cs
- _RegBlobWebProxyDataBuilder.cs
- WebResourceUtil.cs
- smtpconnection.cs
- DirectoryNotFoundException.cs
- SecurityElement.cs
- IProvider.cs
- HtmlMeta.cs
- TypeReference.cs
- DesignOnlyAttribute.cs
- CqlParser.cs
- DataGridViewButtonCell.cs
- UnsafeNativeMethods.cs
- CodeGeneratorAttribute.cs
- WebPartHeaderCloseVerb.cs
- _ConnectOverlappedAsyncResult.cs
- SectionRecord.cs
- ViewgenContext.cs
- SafeWaitHandle.cs
- TCPListener.cs
- GetWorkflowTree.cs
- PointConverter.cs
- ThousandthOfEmRealPoints.cs
- UniformGrid.cs
- CacheVirtualItemsEvent.cs
- WorkflowRuntimeElement.cs
- HttpProfileBase.cs
- FontStyleConverter.cs
- connectionpool.cs
- AuthenticationException.cs
- WebZone.cs
- Rect3D.cs
- WindowsFormsLinkLabel.cs
- SrgsElementFactoryCompiler.cs
- MetabaseServerConfig.cs
- EditCommandColumn.cs
- ThreadInterruptedException.cs
- SymmetricKey.cs
- AmbientLight.cs
- CollaborationHelperFunctions.cs
- TriggerAction.cs
- PersonalizationState.cs
- OrderByLifter.cs
- FragmentQueryProcessor.cs
- TemplateControlCodeDomTreeGenerator.cs
- InteropAutomationProvider.cs
- ObjectDataSourceSelectingEventArgs.cs
- EventArgs.cs
- FontWeights.cs
- LogEntrySerializer.cs
- ScrollViewer.cs
- Logging.cs
- AttributeEmitter.cs
- BmpBitmapDecoder.cs