Esempio n. 1
0
        public SignedBid(Bid bid, Signature sig, MultisigSignature mSig)
        {
            this.bid = JavaHelper <Bid> .RequireNotNull(bid, "tx must not be null");

            this.mSig = JavaHelper <MultisigSignature> .RequireNotNull(mSig, "mSig must not be null");

            this.sig = JavaHelper <Signature> .RequireNotNull(sig, "sig must not be null");
        }
Esempio n. 2
0
        public MultisigSubsig(Ed25519PublicKeyParameters key, Signature sig = null)
        {
            this.key = JavaHelper <Ed25519PublicKeyParameters> .RequireNotNull(key, "public key cannot be null");

            if (sig is null)
            {
                this.sig = new Signature();
            }
            else
            {
                this.sig = sig;
            }
        }
Esempio n. 3
0
        public LogicsigSignature(
            [JsonProperty("l")] byte[] logic,
            [JsonProperty("arg")] List <byte[]> args      = null,
            [JsonProperty("sig")] byte[] sig              = null,
            [JsonProperty("msig")] MultisigSignature msig = null)
        {
            this.logic = JavaHelper <byte[]> .RequireNotNull(logic, "program must not be null");

            this.args = args;

            if (!Logic.CheckProgram(this.logic, this.args))
            {
                throw new Exception("program verified failed!");
            }

            if (sig != null)
            {
                this.sig = new Signature(sig);
            }
            this.msig = msig;
        }