Code:
/ 4.0 / 4.0 / untmp / DEVDIV_TFS / Dev10 / Releases / RTMRel / ndp / cdf / src / WCF / infocard / Client / System / IdentityModel / Selectors / InfoCardRSAOAEPKeyExchangeDeformatter.cs / 1305376 / InfoCardRSAOAEPKeyExchangeDeformatter.cs
//------------------------------------------------------------------------------ // Copyright (c) Microsoft Corporation. All rights reserved. //----------------------------------------------------------------------------- namespace System.IdentityModel.Selectors { using System; using System.Security.Cryptography; internal class InfoCardRSAOAEPKeyExchangeDeformatter : RSAOAEPKeyExchangeDeformatter { private RSA m_rsaKey; // RSA Key value to do decrypt operation // // public constructors // public InfoCardRSAOAEPKeyExchangeDeformatter() : base() {} public InfoCardRSAOAEPKeyExchangeDeformatter( AsymmetricAlgorithm key ) : base( key ) { m_rsaKey = (RSA) key; } // // public methods // public override byte[] DecryptKeyExchange( byte[] rgbData ) { if ( null != m_rsaKey && m_rsaKey is InfoCardRSACryptoProvider ) { return ((InfoCardRSACryptoProvider) m_rsaKey).Decrypt( rgbData, true ); } else { return base.DecryptKeyExchange( rgbData ); } } public override void SetKey( AsymmetricAlgorithm key ) { base.SetKey( key ); m_rsaKey = (RSA) key; } } } // 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
- EventTask.cs
- MappingItemCollection.cs
- DescendentsWalker.cs
- PropertyChangedEventManager.cs
- ObjectStateFormatter.cs
- SingleObjectCollection.cs
- SizeF.cs
- StoreItemCollection.Loader.cs
- TimeSpanStorage.cs
- ProfileSection.cs
- PersonalizationDictionary.cs
- ADConnectionHelper.cs
- OracleLob.cs
- FolderLevelBuildProviderCollection.cs
- NameValueConfigurationElement.cs
- DetailsViewUpdatedEventArgs.cs
- EdmValidator.cs
- SystemResourceKey.cs
- Size3D.cs
- DragSelectionMessageFilter.cs
- WindowsRichEditRange.cs
- SerializableAttribute.cs
- FunctionCommandText.cs
- Publisher.cs
- OLEDB_Util.cs
- WmlCalendarAdapter.cs
- XmlSchemaNotation.cs
- SqlProfileProvider.cs
- PerspectiveCamera.cs
- DateTimePicker.cs
- Int16.cs
- SQLByte.cs
- CopyAction.cs
- GeneratedCodeAttribute.cs
- TextDecoration.cs
- ListItemCollection.cs
- TextTreeNode.cs
- TextEditorThreadLocalStore.cs
- ToolStripCodeDomSerializer.cs
- ChannelSinkStacks.cs
- FileNotFoundException.cs
- HttpRawResponse.cs
- Vector.cs
- TempEnvironment.cs
- ContextMenuStrip.cs
- PageThemeBuildProvider.cs
- SoapFault.cs
- BindingCompleteEventArgs.cs
- DbParameterCollectionHelper.cs
- ContainerAction.cs
- BitmapEffectInputData.cs
- KeyEvent.cs
- SchemaHelper.cs
- DataGridViewRowHeightInfoPushedEventArgs.cs
- _IPv4Address.cs
- SqlBulkCopy.cs
- ModelItemCollectionImpl.cs
- XPathSingletonIterator.cs
- SupportsEventValidationAttribute.cs
- CodeExpressionRuleDeclaration.cs
- DES.cs
- odbcmetadatacollectionnames.cs
- COM2TypeInfoProcessor.cs
- CachedFontFace.cs
- InputReport.cs
- InputQueue.cs
- RequestNavigateEventArgs.cs
- EncoderExceptionFallback.cs
- PersistenceException.cs
- UrlMappingCollection.cs
- UnsafeNativeMethods.cs
- PanelContainerDesigner.cs
- NameSpaceEvent.cs
- ExpressionBinding.cs
- ExtendedProtectionPolicyElement.cs
- CatalogPartCollection.cs
- odbcmetadatacolumnnames.cs
- ListMarkerSourceInfo.cs
- PageSetupDialog.cs
- AnnotationHelper.cs
- InternalConfigRoot.cs
- Trace.cs
- InternalSafeNativeMethods.cs
- TriggerActionCollection.cs
- GlyphElement.cs
- ParallelEnumerable.cs
- DesignOnlyAttribute.cs
- AttachInfo.cs
- GeneralTransformCollection.cs
- AliasExpr.cs
- ColorKeyFrameCollection.cs
- XsltException.cs
- EmbeddedMailObjectsCollection.cs
- DataBinding.cs
- MiniCustomAttributeInfo.cs
- XmlSchemaType.cs
- CapacityStreamGeometryContext.cs
- PolicyManager.cs
- TextAction.cs
- ExpandCollapsePattern.cs