Code:
/ 4.0 / 4.0 / DEVDIV_TFS / Dev10 / Releases / RTMRel / ndp / clr / src / BCL / System / Security / Cryptography / HMACSHA1.cs / 1305376 / 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 FEATURE_CRYPTO if (useManagedSha1) { #endif // FEATURE_CRYPTO m_hash1 = new SHA1Managed(); m_hash2 = new SHA1Managed(); #if FEATURE_CRYPTO } else { m_hash1 = new SHA1CryptoServiceProvider(); m_hash2 = new SHA1CryptoServiceProvider(); } #endif // FEATURE_CRYPTO HashSizeValue = 160; base.InitializeKey(key); } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. // ==++== // // 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 FEATURE_CRYPTO if (useManagedSha1) { #endif // FEATURE_CRYPTO m_hash1 = new SHA1Managed(); m_hash2 = new SHA1Managed(); #if FEATURE_CRYPTO } else { m_hash1 = new SHA1CryptoServiceProvider(); m_hash2 = new SHA1CryptoServiceProvider(); } #endif // FEATURE_CRYPTO HashSizeValue = 160; base.InitializeKey(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
- MailAddressParser.cs
- LineServicesCallbacks.cs
- MessageVersion.cs
- AppliedDeviceFiltersDialog.cs
- BindingNavigator.cs
- IODescriptionAttribute.cs
- NonClientArea.cs
- XmlSchemaAnnotation.cs
- Root.cs
- ThreadPool.cs
- DSACryptoServiceProvider.cs
- UInt16.cs
- XmlQueryStaticData.cs
- DefaultProfileManager.cs
- Model3DGroup.cs
- ContextStack.cs
- ProfileManager.cs
- _LocalDataStoreMgr.cs
- DictionaryEntry.cs
- ChannelSinkStacks.cs
- RefreshPropertiesAttribute.cs
- _UriSyntax.cs
- BinaryUtilClasses.cs
- ValidationUtility.cs
- BamlLocalizableResource.cs
- DynamicDataExtensions.cs
- FixedBufferAttribute.cs
- BuildTopDownAttribute.cs
- SelectionEditor.cs
- KeyNotFoundException.cs
- TextWriter.cs
- namescope.cs
- TreeIterator.cs
- Win32PrintDialog.cs
- SHA1CryptoServiceProvider.cs
- BoolExpression.cs
- ReferencedAssembly.cs
- ArraySegment.cs
- Set.cs
- VisualTarget.cs
- TreeNodeStyle.cs
- LocalizabilityAttribute.cs
- PropertySegmentSerializationProvider.cs
- ListenerConnectionModeReader.cs
- AsymmetricSignatureFormatter.cs
- EventlogProvider.cs
- Win32.cs
- httpstaticobjectscollection.cs
- GridViewHeaderRowPresenter.cs
- XmlSchemaComplexContentExtension.cs
- FrameworkContentElement.cs
- Authorization.cs
- CommandField.cs
- OleDbCommand.cs
- WebPartEditorApplyVerb.cs
- WizardStepBase.cs
- BooleanAnimationUsingKeyFrames.cs
- Span.cs
- Matrix3D.cs
- XslNumber.cs
- XmlNullResolver.cs
- DataService.cs
- Pens.cs
- TimeoutValidationAttribute.cs
- UserControlParser.cs
- DataControlField.cs
- TriggerBase.cs
- DataTableClearEvent.cs
- RequestTimeoutManager.cs
- EntityModelBuildProvider.cs
- AccessViolationException.cs
- SafeFindHandle.cs
- XmlDocument.cs
- PropertyItemInternal.cs
- EntityModelBuildProvider.cs
- PackageFilter.cs
- ObjectViewListener.cs
- ImageMetadata.cs
- HttpWebResponse.cs
- StateInitializationDesigner.cs
- IIS7UserPrincipal.cs
- ReadOnlyAttribute.cs
- QueryOutputWriter.cs
- LinqTreeNodeEvaluator.cs
- AddressingVersion.cs
- ScriptingProfileServiceSection.cs
- TraceEventCache.cs
- StyleBamlTreeBuilder.cs
- IPGlobalProperties.cs
- future.cs
- PageStatePersister.cs
- AuthenticationException.cs
- DivideByZeroException.cs
- InternalSafeNativeMethods.cs
- PresentationUIStyleResources.cs
- GeneralTransform3DTo2DTo3D.cs
- RSACryptoServiceProvider.cs
- Operator.cs
- XamlTypeMapper.cs
- XmlSerializerNamespaces.cs