Post
Topic
Board Armory
Re: Using offline transactions without Armory Online?
by
Muhammed Zakir
on 13/05/2015, 13:41:56 UTC
It was already asked a few times. A search is better.

You can use http://counterwallet.co/ as your online wallet. It give Armory-style transaction and you can broadcast it through your account or via sites which offers broadcasting after copying hex.(see last para)

Or try this script. No warranty or guarantee from me. Use it at your own risk.

-snip-
EDIT: So I figured it out and wrote a script to do this, which will take a bitcoind hex raw txn and convert to an armory style txn, which should be good for signing and/or broadcasting (if already signed) I would think. I couldn't get the system path hack to fully work... it still complained about not being able to import a module in the jsonrpc folder. That being the case, you could just throw this script in /usr/lib/armory on the online armory box (with a full or watch-only wallet) and run it. Starts armory up, loads the blockchain, and spits out the armory-formatted txn.

Any suggestions to the script are welcome (and feel free to add this to the armory extras folder):

Code:
import sys
sys.path.append("/usr/lib/armory")
from armoryengine import *

#See https://bitcoinarmory.com/developers/python-scripting/

if len(sys.argv) != 3:
    print "Please pass wallet file, followed by hex encoded unsigned raw txn"
    sys.exit(2)

walletPath = sys.argv[1]
hexRawTxn = sys.argv[2]

wlt = PyBtcWallet().readWalletFile(walletPath)
# Register wallet and start blockchain scan
TheBDM.registerWallet(wlt)
TheBDM.setBlocking(True)
TheBDM.setOnlineMode(True)  # will take 20 min for rescan
# Need "syncWithBlockchain" every time TheBDM is updated
wlt.syncWithBlockchain()

#Translate raw txn
pytx = PyTx()
print("Encoding raw txn: %s" % hexRawTxn)
binTxn = hex_to_binary(hexRawTxn)
pytx.unserialize(binTxn)
tx = PyTxDistProposal(pytx)
print("\n\nOutput is:\n%s" % tx.serializeAscii())

TheBDM.execCleanShutdown()

After signing with Armory, you can click "Copy (Hex)" which will copy raw transaction which you can broadcast via Blockchain.info or other sites which offers this.

Edit: Below link may help you for broadcasting transactions if Blockchain.info isn't working or is offline.

https://en.bitcoin.it/wiki/Transaction_broadcasting