Code:
/ WCF / WCF / 3.5.30729.1 / untmp / Orcas / SP / ndp / cdf / src / WCF / infocard / Service / managed / Microsoft / InfoCards / RemoteX509Token.cs / 1 / RemoteX509Token.cs
//------------------------------------------------------------------------------ // Copyright (c) Microsoft Corporation. All rights reserved. //----------------------------------------------------------------------------- namespace Microsoft.InfoCards { using System; using System.Collections.Generic; using System.Collections.ObjectModel; using System.Security.Cryptography; using System.Security.Cryptography.X509Certificates; using System.IdentityModel.Tokens; using System.ServiceModel; using System.ServiceModel.Security; using System.ServiceModel.Security.Tokens; using IDT=Microsoft.InfoCards.Diagnostics.InfoCardTrace; // // Summary: // Remotely host key set cert token // class RemoteX509Token : X509SecurityToken { Listm_keys; object m_sync; bool m_disposed; public RemoteX509Token(X509Certificate2 cert) : base( cert ) { m_keys = new List (1); m_keys .Add(new RemoteX509AsymmetricSecurityKey(cert)); m_sync = new object(); } public override ReadOnlyCollection SecurityKeys { get { return m_keys.AsReadOnly(); } } public override void Dispose() { try { if (m_disposed) { return; } lock (m_sync) { if (m_disposed) { return; } m_disposed = true; foreach (SecurityKey key in m_keys) { IDisposable disposable = key as IDisposable; if (null != disposable) { disposable.Dispose(); } } } } finally { base.Dispose(); } } } } // 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
- DataGridViewColumnTypeEditor.cs
- GetCardDetailsRequest.cs
- ListViewItem.cs
- LayeredChannelListener.cs
- DataGridViewDataErrorEventArgs.cs
- SelectedGridItemChangedEvent.cs
- MULTI_QI.cs
- StaticSiteMapProvider.cs
- datacache.cs
- GlyphInfoList.cs
- LinkButton.cs
- TextBoxAutoCompleteSourceConverter.cs
- UnsafeNativeMethods.cs
- ArrangedElementCollection.cs
- ProcessHost.cs
- RequiredAttributeAttribute.cs
- ToolboxItemAttribute.cs
- HtmlTextBoxAdapter.cs
- FixedSOMElement.cs
- WindowsEditBox.cs
- DataGridLinkButton.cs
- MeshGeometry3D.cs
- IpcChannel.cs
- EnterpriseServicesHelper.cs
- SpeechUI.cs
- BitmapVisualManager.cs
- EventToken.cs
- MediaElement.cs
- LocatorPartList.cs
- XPathPatternBuilder.cs
- Style.cs
- GeneralTransform3DTo2DTo3D.cs
- SynchronizationContext.cs
- Vertex.cs
- SiteMapNode.cs
- Triangle.cs
- DataGridAddNewRow.cs
- ColorMatrix.cs
- HttpClientCredentialType.cs
- DoubleKeyFrameCollection.cs
- SymmetricAlgorithm.cs
- WebPartCatalogAddVerb.cs
- SafeThemeHandle.cs
- FamilyCollection.cs
- DataGridColumnCollection.cs
- ItemMap.cs
- HtmlForm.cs
- DataControlFieldHeaderCell.cs
- CodeGen.cs
- COM2ComponentEditor.cs
- Activator.cs
- AttributeCollection.cs
- SingleAnimation.cs
- AppDomainShutdownMonitor.cs
- RuleSetDialog.Designer.cs
- ItemCollection.cs
- Math.cs
- MetadataSerializer.cs
- DataSetUtil.cs
- RequestResizeEvent.cs
- _emptywebproxy.cs
- FrugalList.cs
- SpecularMaterial.cs
- WindowsImpersonationContext.cs
- ProtocolsConfigurationHandler.cs
- MessageBox.cs
- Hash.cs
- ConnectionStringsExpressionEditor.cs
- DesignerLabelAdapter.cs
- WinCategoryAttribute.cs
- EdmMember.cs
- GenericEnumConverter.cs
- ReverseQueryOperator.cs
- ZipArchive.cs
- EntityTemplateUserControl.cs
- SymbolPair.cs
- BaseProcessor.cs
- DynamicAttribute.cs
- GeometryCollection.cs
- AccessDataSource.cs
- HttpStreamMessage.cs
- DBCSCodePageEncoding.cs
- XmlUnspecifiedAttribute.cs
- XappLauncher.cs
- SQLInt64Storage.cs
- FontFamily.cs
- Material.cs
- XslNumber.cs
- UnsafeNativeMethods.cs
- BaseResourcesBuildProvider.cs
- Token.cs
- Point4D.cs
- TraceHwndHost.cs
- ServicePoint.cs
- PackageFilter.cs
- PageThemeParser.cs
- WebPartRestoreVerb.cs
- Popup.cs
- HwndSourceParameters.cs
- Registry.cs