CreateSignature() абстрактный публичный Метод

abstract public CreateSignature ( byte rgbHash ) : byte[]
rgbHash byte
Результат byte[]
Пример #1
0
 // Create a signature for a specified hash value.
 public override byte[] CreateSignature(byte[] rgbHash)
 {
     if (keyContainer == null)
     {
         throw new CryptographicException
                   (_("Crypto_MissingKey"));
     }
     return(keyContainer.CreateSignature(rgbHash));
 }
Пример #2
0
        public override byte[] CreateSignature(byte[] rgbHash)
        {
            if (dsa == null)
            {
                throw new CryptographicUnexpectedOperationException(
                          Locale.GetText("missing key"));
            }

            return(dsa.CreateSignature(rgbHash));
        }
        public override Signature Sign(byte[] data)
        {
            //Synchronize around the hash algorithm to prevent collisions.
            lock (hashAlgorithm)
            {
                //Initialize the hash algorithm.
                hashAlgorithm.Initialize();

                //Sign the data, providing the identity of the signer and the original data.
                return(new DSASignature(data, identity, dsa.CreateSignature(hashAlgorithm.ComputeHash(data))));
            }
        }
Пример #4
0
        public override byte[] CreateSignature(byte[] rgbHash)
        {
            if (rgbHash == null)
            {
                throw new ArgumentNullException(nameof(rgbHash));
            }
            if (_dsaKey == null)
            {
                throw new CryptographicUnexpectedOperationException(SR.Cryptography_MissingKey);
            }

            return(_dsaKey.CreateSignature(rgbHash));
        }
        public override byte[] CreateSignature(byte[] rgbHash)
        {
            if (rgbHash == null)
            {
                throw new ArgumentNullException("rgbHash");
            }
            Contract.EndContractBlock();

            if (_oid == null)
            {
                throw new CryptographicUnexpectedOperationException(Environment.GetResourceString("Cryptography_MissingOID"));
            }
            if (_dsaKey == null)
            {
                throw new CryptographicUnexpectedOperationException(Environment.GetResourceString("Cryptography_MissingKey"));
            }

            return(_dsaKey.CreateSignature(rgbHash));
        }
        /// <include file='doc\DSASignatureFormatter.uex' path='docs/doc[@for="DSASignatureFormatter.CreateSignature"]/*' />
        public override byte[] CreateSignature(byte[] rgbHash)
        {
            byte[] rgbSig;

            if (_strOID == null)
            {
                throw new CryptographicUnexpectedOperationException(Environment.GetResourceString("Cryptography_MissingOID"));
            }
            if (_dsaKey == null)
            {
                throw new CryptographicUnexpectedOperationException(Environment.GetResourceString("Cryptography_MissingKey"));
            }
            if (rgbHash == null)
            {
                throw new ArgumentNullException("rgbHash");
            }

            rgbSig = _dsaKey.CreateSignature(rgbHash);

            return(rgbSig);
        }
Пример #7
0
 public override byte[] CreateSignature(byte[] rgbHash) => _impl.CreateSignature(rgbHash);
Пример #8
0
 public override byte[] CreateSignature(byte[] rgbHash) =>
 _wrapped.CreateSignature(rgbHash);