Code:
/ 4.0 / 4.0 / untmp / DEVDIV_TFS / Dev10 / Releases / RTMRel / ndp / clr / src / BCL / System / Security / Cryptography / KeyedHashAlgorithm.cs / 1305376 / KeyedHashAlgorithm.cs
// ==++== // // Copyright (c) Microsoft Corporation. All rights reserved. // // ==--== //[....] // // // KeyedHashAlgorithm.cs // namespace System.Security.Cryptography { [System.Runtime.InteropServices.ComVisible(true)] public abstract class KeyedHashAlgorithm : HashAlgorithm { protected byte[] KeyValue; protected KeyedHashAlgorithm() {} // IDisposable methods protected override void Dispose(bool disposing) { // For keyed hash algorithms, we always want to zero out the key value if (disposing) { if (KeyValue != null) Array.Clear(KeyValue, 0, KeyValue.Length); KeyValue = null; } base.Dispose(disposing); } // // public properties // public virtual byte[] Key { get { return (byte[]) KeyValue.Clone(); } set { if (State != 0) throw new CryptographicException(Environment.GetResourceString("Cryptography_HashKeySet")); KeyValue = (byte[]) value.Clone(); } } // // public methods // [System.Security.SecuritySafeCritical] // auto-generated new static public KeyedHashAlgorithm Create() { return Create("System.Security.Cryptography.KeyedHashAlgorithm"); } [System.Security.SecuritySafeCritical] // auto-generated new static public KeyedHashAlgorithm Create(String algName) { return (KeyedHashAlgorithm) CryptoConfig.CreateFromName(algName); } } } // 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
- SharedPerformanceCounter.cs
- JobInputBins.cs
- DeclaredTypeElement.cs
- NameValuePermission.cs
- MergeFilterQuery.cs
- SqlDataReader.cs
- ItemsPresenter.cs
- CustomActivityDesigner.cs
- Debug.cs
- MarshalByValueComponent.cs
- MetadataItemEmitter.cs
- HttpInputStream.cs
- QuaternionAnimationBase.cs
- MarkupWriter.cs
- SerialReceived.cs
- ControlBindingsConverter.cs
- CodeIndexerExpression.cs
- PageRanges.cs
- ExpressionPrinter.cs
- ExceptionHandler.cs
- KnownBoxes.cs
- ReaderWriterLock.cs
- RadioButtonList.cs
- LinearKeyFrames.cs
- EntityDataSourceColumn.cs
- ServiceProviders.cs
- CommonDialog.cs
- ControlIdConverter.cs
- DmlSqlGenerator.cs
- SerialPort.cs
- CheckoutException.cs
- WorkflowServiceBuildProvider.cs
- WebPartPersonalization.cs
- ToolStripContentPanel.cs
- connectionpool.cs
- TemplateBaseAction.cs
- PointUtil.cs
- Transactions.cs
- RuntimeHandles.cs
- InitializerFacet.cs
- CharStorage.cs
- CompletionProxy.cs
- XmlSchemaSet.cs
- TextMessageEncodingElement.cs
- XmlUtilWriter.cs
- SapiRecoInterop.cs
- PropertyMetadata.cs
- BrowserTree.cs
- TypedColumnHandler.cs
- Int32AnimationBase.cs
- BitSet.cs
- DataPagerField.cs
- ToolBarButtonClickEvent.cs
- ExpressionValueEditor.cs
- Vector3DAnimationUsingKeyFrames.cs
- IntSecurity.cs
- WebPartManager.cs
- CatalogPart.cs
- KeyedQueue.cs
- DateTimeOffsetStorage.cs
- SqlMethodAttribute.cs
- Relationship.cs
- ArrangedElement.cs
- UnsignedPublishLicense.cs
- TableChangeProcessor.cs
- DrawingAttributeSerializer.cs
- FilterEventArgs.cs
- InternalDispatchObject.cs
- HttpPostedFile.cs
- GenericUI.cs
- UnsafeNativeMethods.cs
- CodeParameterDeclarationExpressionCollection.cs
- Light.cs
- RepeaterItemCollection.cs
- DirectoryObjectSecurity.cs
- XmlSchemaValidator.cs
- SmtpNetworkElement.cs
- QilTernary.cs
- SelectedGridItemChangedEvent.cs
- BinaryUtilClasses.cs
- Choices.cs
- ThemeDirectoryCompiler.cs
- DbConnectionStringCommon.cs
- XmlEncoding.cs
- typedescriptorpermissionattribute.cs
- AnnotationMap.cs
- References.cs
- TreeNodeBinding.cs
- HtmlTableRow.cs
- RequestCachingSection.cs
- XmlCodeExporter.cs
- BamlBinaryWriter.cs
- SessionPageStateSection.cs
- BamlLocalizationDictionary.cs
- ExtensionQuery.cs
- Switch.cs
- XmlSchemaAttributeGroupRef.cs
- AssociationTypeEmitter.cs
- ContextDataSourceContextData.cs
- BufferedStream.cs