Code:
/ WCF / WCF / 3.5.30729.1 / untmp / Orcas / SP / ndp / cdf / src / WCF / ServiceModel / System / ServiceModel / Channels / SecurityCapabilities.cs / 1 / SecurityCapabilities.cs
//------------------------------------------------------------------------------ // Copyright (c) Microsoft Corporation. All rights reserved. //----------------------------------------------------------------------------- namespace System.ServiceModel.Channels { using System.Net.Security; class SecurityCapabilities : ISecurityCapabilities { internal bool supportsServerAuth; internal bool supportsClientAuth; internal bool supportsClientWindowsIdentity; internal ProtectionLevel requestProtectionLevel; internal ProtectionLevel responseProtectionLevel; public SecurityCapabilities(bool supportsClientAuth, bool supportsServerAuth, bool supportsClientWindowsIdentity, ProtectionLevel requestProtectionLevel, ProtectionLevel responseProtectionLevel) { this.supportsClientAuth = supportsClientAuth; this.supportsServerAuth = supportsServerAuth; this.supportsClientWindowsIdentity = supportsClientWindowsIdentity; this.requestProtectionLevel = requestProtectionLevel; this.responseProtectionLevel = responseProtectionLevel; } public ProtectionLevel SupportedRequestProtectionLevel { get { return requestProtectionLevel; } } public ProtectionLevel SupportedResponseProtectionLevel { get { return responseProtectionLevel; } } public bool SupportsClientAuthentication { get { return supportsClientAuth; } } public bool SupportsClientWindowsIdentity { get { return supportsClientWindowsIdentity; } } public bool SupportsServerAuthentication { get { return supportsServerAuth; } } static SecurityCapabilities None { get { return new SecurityCapabilities(false, false, false, ProtectionLevel.None, ProtectionLevel.None); } } internal static bool IsEqual(ISecurityCapabilities capabilities1, ISecurityCapabilities capabilities2) { if (capabilities1 == null) { capabilities1 = SecurityCapabilities.None; } if (capabilities2 == null) { capabilities2 = SecurityCapabilities.None; } if (capabilities1.SupportedRequestProtectionLevel != capabilities2.SupportedRequestProtectionLevel) { return false; } if (capabilities1.SupportedResponseProtectionLevel != capabilities2.SupportedResponseProtectionLevel) { return false; } if (capabilities1.SupportsClientAuthentication != capabilities2.SupportsClientAuthentication) { return false; } if (capabilities1.SupportsClientWindowsIdentity != capabilities2.SupportsClientWindowsIdentity) { return false; } if (capabilities1.SupportsServerAuthentication != capabilities2.SupportsServerAuthentication) { return false; } return true; } } } // 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
- ImageClickEventArgs.cs
- OleDbTransaction.cs
- PersonalizationEntry.cs
- CombinedGeometry.cs
- CollectionBase.cs
- RecordManager.cs
- DebugInfo.cs
- MSHTMLHostUtil.cs
- MenuItemCollection.cs
- ErrorWebPart.cs
- LinqDataSourceInsertEventArgs.cs
- EnumerableRowCollection.cs
- SkipQueryOptionExpression.cs
- EndpointIdentityConverter.cs
- BamlRecordReader.cs
- HttpRequestCacheValidator.cs
- DetailsViewCommandEventArgs.cs
- CatalogPartCollection.cs
- UIElementParaClient.cs
- GiveFeedbackEventArgs.cs
- ConfigsHelper.cs
- VirtualDirectoryMappingCollection.cs
- UnsafeNativeMethods.cs
- SchemaHelper.cs
- DataGridBoolColumn.cs
- ThemeableAttribute.cs
- ReturnEventArgs.cs
- InputScope.cs
- RemotingSurrogateSelector.cs
- AssemblyName.cs
- DataErrorValidationRule.cs
- DefaultSection.cs
- AttributeEmitter.cs
- SchemaMerger.cs
- Compiler.cs
- DataGridViewAutoSizeColumnsModeEventArgs.cs
- RunInstallerAttribute.cs
- MemoryFailPoint.cs
- ColorAnimationUsingKeyFrames.cs
- ConstraintStruct.cs
- XamlReader.cs
- WindowsListViewGroupHelper.cs
- WebPartsSection.cs
- PagesSection.cs
- StyleSheet.cs
- Tokenizer.cs
- ParentUndoUnit.cs
- HTTPNotFoundHandler.cs
- DecoderFallback.cs
- TextParentUndoUnit.cs
- SelectedCellsCollection.cs
- SemanticResultKey.cs
- Parameter.cs
- RequestQueryParser.cs
- XmlSchemaAnnotation.cs
- DesignerHost.cs
- RSAOAEPKeyExchangeFormatter.cs
- ISAPIApplicationHost.cs
- Touch.cs
- ACL.cs
- CodeSnippetTypeMember.cs
- XmlSchemaChoice.cs
- MethodMessage.cs
- RelationshipManager.cs
- _BaseOverlappedAsyncResult.cs
- XmlWriter.cs
- SrgsElementFactory.cs
- DataServiceRequestException.cs
- FileDialog.cs
- OdbcConnectionStringbuilder.cs
- FrameSecurityDescriptor.cs
- SrgsGrammar.cs
- PropertyValueChangedEvent.cs
- SerializationAttributes.cs
- EntityDataReader.cs
- CodeGotoStatement.cs
- WebPageTraceListener.cs
- InitialServerConnectionReader.cs
- DragDrop.cs
- Rect3D.cs
- VisemeEventArgs.cs
- UnsafeNativeMethods.cs
- SqlRetyper.cs
- CatalogPartCollection.cs
- ActivityExecutorOperation.cs
- ComAdminWrapper.cs
- WindowsListBox.cs
- PersonalizationStateInfoCollection.cs
- DesignBindingConverter.cs
- CopyNodeSetAction.cs
- RadioButton.cs
- BufferBuilder.cs
- CodeConditionStatement.cs
- InputScopeConverter.cs
- DoubleCollectionConverter.cs
- PublishLicense.cs
- DesignColumnCollection.cs
- ThemeConfigurationDialog.cs
- GlyphRun.cs
- DocumentViewer.cs