コード例 #1
0
        listOptions['spending_txid'], False)
    listOptions['spending_tx_decoded'] = conn.decoderawtransaction(
        listOptions['spending_tx_raw'])
    listOptions['decoded_mptx'] = conn.decoderawtransaction(
        ''.join(hex_transaction))
    listOptions['p2sh_addr_pubkey'] = (raw_input(
        "Please enter the MULTISIG ADDRESS PUBLIC KEY (scriptPubkey) from the above that will be spent, required:\n(Enter to use: "
        + str(p2sh_scriptPubkey) + ")") or p2sh_scriptPubkey)
    #listOptions['p2sh_addr_pubkey']=p2sh_scriptPubkey
    listOptions['p2sh_redeemscript'] = (raw_input(
        "Please enter the MULTISIG ADDRESS REDEEM SCRIPT from the above , required:\n(Enter to use: "
        + str(p2sh_rscript) + ")") or p2sh_rscript)
    #listOptions['p2sh_redeemscript']=p2sh_rscript
    #= conn.validateaddress(listOptions['transaction_from']).hex

    rawhex = holyscript.holySignor(listOptions, ''.join(hex_transaction),
                                   testnet)

    print ''
    print 'This is your ARMORY hex: '
    print rawhex
    print ''

if '-ui' in sys.argv:
    #dump unsigned
    print ''
    print 'This is your hex: '
    print ''.join(hex_transaction)
    print ''
    sign_it = raw_input('Would you like to sign it now? [yes OR no]')
    if sign_it == 'yes':
        import P2SH_signer
コード例 #2
0
#output final product as JSON

if '-armory' in sys.argv:
  sys.argv = ['ArmoryQt.py']
  import holyscript
  listOptions['spending_tx_raw'] = conn.getrawtransaction(listOptions['spending_txid'], False)
  listOptions['spending_tx_decoded'] = conn.decoderawtransaction(listOptions['spending_tx_raw'])
  listOptions['decoded_mptx'] = conn.decoderawtransaction(''.join(hex_transaction))
  listOptions['p2sh_addr_pubkey']=(raw_input("Please enter the MULTISIG ADDRESS PUBLIC KEY (scriptPubkey) from the above that will be spent, required:\n(Enter to use: "+str(p2sh_scriptPubkey)+")") or p2sh_scriptPubkey) 
  #listOptions['p2sh_addr_pubkey']=p2sh_scriptPubkey
  listOptions['p2sh_redeemscript']=(raw_input("Please enter the MULTISIG ADDRESS REDEEM SCRIPT from the above , required:\n(Enter to use: "+str(p2sh_rscript)+")") or p2sh_rscript)  
  #listOptions['p2sh_redeemscript']=p2sh_rscript 
    #= conn.validateaddress(listOptions['transaction_from']).hex

  rawhex = holyscript.holySignor(listOptions, ''.join(hex_transaction), testnet) 

  print ''
  print 'This is your ARMORY hex: '
  print rawhex
  print ''

if '-ui' in sys.argv:
  #dump unsigned
  print ''
  print 'This is your hex: '
  print ''.join(hex_transaction)
  print ''
  sign_it=raw_input('Would you like to sign it now? [yes OR no]')
  if sign_it == 'yes':
     import P2SH_signer