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
- MenuItemCollection.cs
- UnsafeMethods.cs
- LogicalTreeHelper.cs
- CollectionChangeEventArgs.cs
- KoreanLunisolarCalendar.cs
- EmptyStringExpandableObjectConverter.cs
- Pair.cs
- TranslateTransform.cs
- WebPartEditorCancelVerb.cs
- UnauthorizedWebPart.cs
- PointCollection.cs
- ResourceDescriptionAttribute.cs
- GlobalizationSection.cs
- GlyphManager.cs
- FrameworkContentElement.cs
- GradientSpreadMethodValidation.cs
- TypeConverterHelper.cs
- Pen.cs
- Font.cs
- SafeCryptoHandles.cs
- FixedTextPointer.cs
- HttpListenerResponse.cs
- XmlSchemaExternal.cs
- CommonDialog.cs
- AssemblyName.cs
- GradientStopCollection.cs
- TraceContextEventArgs.cs
- XsdCachingReader.cs
- BindingMemberInfo.cs
- ProvideValueServiceProvider.cs
- Descriptor.cs
- InertiaExpansionBehavior.cs
- ObfuscationAttribute.cs
- BorderGapMaskConverter.cs
- SmtpClient.cs
- MergablePropertyAttribute.cs
- BindToObject.cs
- JapaneseCalendar.cs
- PathTooLongException.cs
- Math.cs
- TableLayoutPanelBehavior.cs
- FormsAuthenticationCredentials.cs
- ListItem.cs
- Rotation3DAnimationUsingKeyFrames.cs
- XmlHierarchicalEnumerable.cs
- ProbeMatchesApril2005.cs
- ConstNode.cs
- ContentTextAutomationPeer.cs
- TreeNodeStyleCollection.cs
- VirtualStackFrame.cs
- SortedSet.cs
- MemberAssignmentAnalysis.cs
- CopyAction.cs
- SpotLight.cs
- TextEffect.cs
- PasswordBoxAutomationPeer.cs
- ContractMapping.cs
- ElementAction.cs
- ValidationSummary.cs
- codemethodreferenceexpression.cs
- DataGridViewDataErrorEventArgs.cs
- PlainXmlSerializer.cs
- TailCallAnalyzer.cs
- MailDefinition.cs
- TextSimpleMarkerProperties.cs
- DataGrid.cs
- ContractHandle.cs
- FrameworkTextComposition.cs
- DeflateStreamAsyncResult.cs
- FtpWebRequest.cs
- XmlValidatingReaderImpl.cs
- BrowserDefinition.cs
- EmptyControlCollection.cs
- DirectoryObjectSecurity.cs
- WebPartMenu.cs
- RandomNumberGenerator.cs
- DataGridCellEditEndingEventArgs.cs
- Transform.cs
- DataTableReaderListener.cs
- EventRoute.cs
- DiagnosticsConfiguration.cs
- MemberExpression.cs
- ConstantCheck.cs
- PocoEntityKeyStrategy.cs
- DataGridViewSelectedCellCollection.cs
- GeneralTransform.cs
- KeyedHashAlgorithm.cs
- AffineTransform3D.cs
- AddressHeaderCollection.cs
- SerializationInfoEnumerator.cs
- StandardRuntimeEnumValidator.cs
- BlurBitmapEffect.cs
- SerializationException.cs
- StreamGeometry.cs
- CapabilitiesState.cs
- EntityContainerRelationshipSetEnd.cs
- OrderedDictionary.cs
- Peer.cs
- SystemIPInterfaceStatistics.cs
- OdbcUtils.cs