Code:
/ FXUpdate3074 / FXUpdate3074 / 1.1 / untmp / whidbey / QFE / ndp / clr / src / BCL / System / Security / Cryptography / HMACSHA1.cs / 1 / HMACSHA1.cs
// ==++==
//
// Copyright (c) Microsoft Corporation. All rights reserved.
//
// ==--==
//
// HMACSHA1.cs
//
namespace System.Security.Cryptography {
[System.Runtime.InteropServices.ComVisible(true)]
public class HMACSHA1 : HMAC {
//
// public constructors
//
public HMACSHA1 () : this (Utils.GenerateRandom(64)) {}
public HMACSHA1 (byte[] key) : this (key, false) {}
public HMACSHA1 (byte[] key, bool useManagedSha1) {
m_hashName = "SHA1";
if (useManagedSha1) {
m_hash1 = new SHA1Managed();
m_hash2 = new SHA1Managed();
} else {
m_hash1 = new SHA1CryptoServiceProvider();
m_hash2 = new SHA1CryptoServiceProvider();
}
HashSizeValue = 160;
base.InitializeKey(key);
}
}
}
// 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
- TypedReference.cs
- RegexStringValidator.cs
- Matrix.cs
- SimpleWorkerRequest.cs
- FixedLineResult.cs
- Brush.cs
- RegexBoyerMoore.cs
- PropertyPathConverter.cs
- TreeNodeSelectionProcessor.cs
- XmlDsigSep2000.cs
- AsymmetricSignatureDeformatter.cs
- InternalCompensate.cs
- SessionEndedEventArgs.cs
- ImmutableObjectAttribute.cs
- GraphicsPath.cs
- TypeUnloadedException.cs
- RemoteX509AsymmetricSecurityKey.cs
- TransformPattern.cs
- PropertyItemInternal.cs
- OnOperation.cs
- ConfigurationPermission.cs
- FacetValues.cs
- WS2007FederationHttpBindingElement.cs
- AggregateNode.cs
- XamlDesignerSerializationManager.cs
- MethodExpression.cs
- MimeTypePropertyAttribute.cs
- PersonalizationStateInfo.cs
- ServiceBehaviorElementCollection.cs
- clipboard.cs
- UIAgentCrashedException.cs
- Inflater.cs
- CodeRemoveEventStatement.cs
- HtmlEncodedRawTextWriter.cs
- Transform3D.cs
- ColorKeyFrameCollection.cs
- TdsEnums.cs
- TextServicesPropertyRanges.cs
- SatelliteContractVersionAttribute.cs
- TextRangeEditTables.cs
- NameTable.cs
- QueryBranchOp.cs
- CancellationHandler.cs
- Debugger.cs
- LineServices.cs
- LabelDesigner.cs
- FaultContractInfo.cs
- ValueQuery.cs
- XmlResolver.cs
- DataExchangeServiceBinder.cs
- ToolStripKeyboardHandlingService.cs
- HMACSHA384.cs
- ContainerParaClient.cs
- UseAttributeSetsAction.cs
- ColumnReorderedEventArgs.cs
- IntegerValidatorAttribute.cs
- BitArray.cs
- ObjectSecurity.cs
- KeySpline.cs
- DataControlPagerLinkButton.cs
- ColumnReorderedEventArgs.cs
- ByteStack.cs
- GlyphCache.cs
- InputDevice.cs
- SynchronousReceiveBehavior.cs
- OpenFileDialog.cs
- CodeIdentifier.cs
- FileDialogCustomPlace.cs
- EntityProxyTypeInfo.cs
- RegexRunner.cs
- StrongNameUtility.cs
- SimpleApplicationHost.cs
- ColorConvertedBitmap.cs
- EntitySqlQueryCacheKey.cs
- Popup.cs
- GenericEnumerator.cs
- ObjectStateEntryOriginalDbUpdatableDataRecord.cs
- HtmlTextArea.cs
- COM2ExtendedBrowsingHandler.cs
- MasterPage.cs
- TypeUtil.cs
- FastEncoder.cs
- ConfigXmlAttribute.cs
- ListViewVirtualItemsSelectionRangeChangedEvent.cs
- ChtmlTextBoxAdapter.cs
- Single.cs
- BmpBitmapDecoder.cs
- ParameterEditorUserControl.cs
- RegistrationServices.cs
- SafeTokenHandle.cs
- DropDownHolder.cs
- TableRow.cs
- SourceFilter.cs
- XmlSchemaInclude.cs
- EncodingFallbackAwareXmlTextWriter.cs
- ReferencedCategoriesDocument.cs
- CounterSample.cs
- AsyncOperation.cs
- QuaternionRotation3D.cs
- namescope.cs