コード例 #1
0
ファイル: Script.cs プロジェクト: nikserdev/BitcoinSharp
        /// <summary>
        /// Replaces the top item in the stack with a hash160 of it
        /// </summary>
        private void ProcessOpHash160()
        {
            var buf  = _stack.Pop();
            var hash = Utils.Sha256Hash160(buf);

            _stack.Push(hash);
            _log.DebugFormat("HASH160: output is {0}", Utils.BytesToHexString(hash));
        }
コード例 #2
0
        /// <summary>
        /// Returns the address that corresponds to the public part of this ECKey. Note that an address is derived from
        /// the RIPEMD-160 hash of the public key and is not the public key itself (which is too large to be convenient).
        /// </summary>
        public Address ToAddress(NetworkParameters @params)
        {
            var hash160 = Utils.Sha256Hash160(_pub);

            return(new Address(@params, hash160));
        }