Exemplo n.º 1
0
        /// <summary>
        /// Initializes a new instance of the <see cref="DsaDigitalSignature" /> class.
        /// </summary>
        /// <param name="key">The DSA key.</param>
        /// <exception cref="System.ArgumentNullException">key</exception>
        public DsaDigitalSignature(DsaKey key)
        {
            if (key == null)
            {
                throw new ArgumentNullException("key");
            }

            this._key = key;

            this._hash = new SHA1Hash();
        }
Exemplo n.º 2
0
        /// <summary>
        /// Initializes a new instance of the <see cref="DsaDigitalSignature" /> class.
        /// </summary>
        /// <param name="key">The DSA key.</param>
        /// <exception cref="System.ArgumentNullException">key</exception>
        public DsaDigitalSignature(DsaKey key)
        {
            if (key == null)
            {
                throw new ArgumentNullException("key");
            }

            this._key = key;

            this._hash = HashAlgorithmFactory.CreateSHA1();
        }
Exemplo n.º 3
0
        /// <summary>
        /// Initializes a new instance of the <see cref="DsaDigitalSignature" /> class.
        /// </summary>
        /// <param name="key">The DSA key.</param>
        /// <exception cref="System.ArgumentNullException">key</exception>
        public DsaDigitalSignature(DsaKey key)
        {
            if (key == null)
            {
                throw new ArgumentNullException("key");
            }

            _key = key;

            _hash = CryptoAbstraction.CreateSha1();
        }
        /// <summary>
        /// Initializes a new instance of the <see cref="DsaDigitalSignature"/> class.
        /// </summary>
        /// <param name="key">The DSA key.</param>
        public DsaDigitalSignature(DsaKey key)
        {
            if (key == null)
            {
                throw new ArgumentNullException("key");
            }

            this._key = key;

            this._hash = HashAlgorithmProvider.OpenAlgorithm(HashAlgorithmNames.Sha1).CreateHash();
        }