Code:
/ DotNET / DotNET / 8.0 / untmp / whidbey / REDBITS / ndp / clr / src / BCL / System / Security / Cryptography / KeyedHashAlgorithm.cs / 1 / 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 // new static public KeyedHashAlgorithm Create() { return Create("System.Security.Cryptography.KeyedHashAlgorithm"); } new static public KeyedHashAlgorithm Create(String algName) { return (KeyedHashAlgorithm) CryptoConfig.CreateFromName(algName); } } }
Link Menu
This book is available now!
Buy at Amazon US or
Buy at Amazon UK
- CreateUserErrorEventArgs.cs
- _IPv6Address.cs
- PageCatalogPart.cs
- GenericPrincipal.cs
- WebPartsPersonalization.cs
- StylusLogic.cs
- Stylesheet.cs
- TimeSpanStorage.cs
- WSDualHttpSecurityMode.cs
- XmlIlTypeHelper.cs
- GlyphingCache.cs
- WindowCollection.cs
- ToolStripSplitStackLayout.cs
- SpecialNameAttribute.cs
- ContractsBCL.cs
- CacheVirtualItemsEvent.cs
- CallInfo.cs
- DateTimeParse.cs
- UTF8Encoding.cs
- WebPartDisplayMode.cs
- DoubleLink.cs
- HttpVersion.cs
- WsatStrings.cs
- LoginCancelEventArgs.cs
- BaseTemplateCodeDomTreeGenerator.cs
- TextPointer.cs
- TextBoxView.cs
- MenuAdapter.cs
- XsdDuration.cs
- SecurityTokenValidationException.cs
- InvalidFilterCriteriaException.cs
- DataGridItem.cs
- DataColumnMapping.cs
- EnterpriseServicesHelper.cs
- CellParagraph.cs
- GradientStop.cs
- InsufficientMemoryException.cs
- TreeViewEvent.cs
- LazyLoadBehavior.cs
- EntityDataSourceDataSelection.cs
- WeakHashtable.cs
- SchemaCollectionPreprocessor.cs
- SimpleTypeResolver.cs
- SqlServices.cs
- DynamicILGenerator.cs
- AnimationClockResource.cs
- AtomServiceDocumentSerializer.cs
- LocalValueEnumerator.cs
- SystemGatewayIPAddressInformation.cs
- DataGridViewEditingControlShowingEventArgs.cs
- BindingExpression.cs
- RectangleHotSpot.cs
- QueueAccessMode.cs
- ChildrenQuery.cs
- ListViewVirtualItemsSelectionRangeChangedEvent.cs
- StringInfo.cs
- CriticalFinalizerObject.cs
- FormatVersion.cs
- _UriSyntax.cs
- StrongTypingException.cs
- TrackingRecord.cs
- EmptyStringExpandableObjectConverter.cs
- SettingsPropertyValue.cs
- EncryptedData.cs
- GenericAuthenticationEventArgs.cs
- ProviderIncompatibleException.cs
- GroupBox.cs
- ObjectReferenceStack.cs
- Control.cs
- ConfigurationSectionGroup.cs
- Version.cs
- CanExecuteRoutedEventArgs.cs
- SqlTriggerAttribute.cs
- _RequestCacheProtocol.cs
- XmlElementCollection.cs
- ProjectionCamera.cs
- TextPenaltyModule.cs
- DataServiceClientException.cs
- DateTimeFormatInfoScanner.cs
- SimplePropertyEntry.cs
- HiddenField.cs
- shaperfactoryquerycacheentry.cs
- LaxModeSecurityHeaderElementInferenceEngine.cs
- CollectionDataContractAttribute.cs
- CellNormalizer.cs
- SqlDataSourceWizardForm.cs
- EntityClientCacheEntry.cs
- BufferedGraphics.cs
- MaskedTextBoxTextEditor.cs
- WebPartZoneDesigner.cs
- DbConnectionStringBuilder.cs
- NamedObject.cs
- SqlCacheDependencyDatabaseCollection.cs
- WebPartConnection.cs
- ActivityMarkupSerializer.cs
- CompositeCollection.cs
- ServiceBuildProvider.cs
- DataBoundLiteralControl.cs
- DataTableNewRowEvent.cs
- Point3D.cs