Wolfram Computation Meets Knowledge

BlockchainTransactionSign(for ARK)

$BlockchainBase = "ARK"

BlockchainTransactionSign[obj,key]

用指定的私钥对 ARK 区块链交易进行数字签名.

BlockchainTransactionSign[obj,{key1,key2}]

使用第一私钥和第二私钥对交易进行数字签名.

BlockchainTransactionSign[obj,{assoc1,assoc2,}]

digitally signs a transaction related to a multisignature address.

更多信息

  • 用指定的私钥对 ARK 区块链交易进行数字签名. 如果地址具有与之关联的第二个公钥,则必须提供第二个私钥来对交易进行签名.
  • If the sender is a multisignature address, a list of associations with the private key of each participant must be given to sign the transaction. A minimum number of keys must be provided according to the "MinimumKeys" parameter of the multisignature address.
  • BlockchainTransactionSign[obj,] 中,obj 是一个 BlockchainTransaction 对象.
  • BlockchainTransactionSign 的密钥必须是一个 PrivateKey 对象、表示私钥的十六进制字符串或 WIF 格式的私钥.
  • BlockchainTransactionSign 返回一个区块链交易对象,其属性 "Signed" 的值为 True,并同时具有附加属性 "RawTransaction".

范例

打开所有单元关闭所有单元

基本范例  (1)

创建一个 ARK BlockchainTransaction:

用私钥对象对交易对象进行签名:

范围  (5)

WIF 私钥  (1)

用 WIF 私钥对 ARK 交易对象进行签名:

Hexadecimal 私钥  (1)

用十六进制私钥对 ARK 交易对象进行签名:

第二签名地址  (1)

当发送者的地址具有与之关联的第二签名时:

必须在列表中使用所需的私钥对交易进行签名:

Multisignature Creation  (1)

Sign an ARK transaction to create a multisignature address:

The transaction must be signed with the private keys of all of the participants:

The transaction must be signed by the sender using the private key associated with the "SenderPublicKey" field given when creating the transaction object:

Multisignature Address as Sender  (1)

Sign an ARK transaction with a multisignature address as sender. In this case, the "SenderPublicKey" is mandatory

The transaction must be signed with a minimum number of private keys from the participants according to the "MinimumKeys" parameter of the multisignature address:

可能存在的问题  (1)

不正确的私钥  (1)

如果提供了无效的私钥,将返回 $Failed

2019年引入
 (12.0)