Updates to allow verify_ledger_json.js to calculate account_state hash

This commit is contained in:
Nicholas Dudfield
2014-05-06 13:34:01 +07:00
parent 473d8a8d8c
commit a222f2be98
7 changed files with 156 additions and 139 deletions

View File

@@ -9,6 +9,8 @@ if (process.argc < 1) {
var json = fs.readFileSync(process.argv[2], 'utf-8');
var ledger = Ledger.from_json(JSON.parse(json));
console.log("Calculated transaction hash: "+ledger.calc_tx_hash().to_hex())
console.log("Transaction hash in header: "+ledger.ledger_json.transaction_hash);
console.log("Calculated transaction hash: "+ledger.calc_tx_hash().to_hex());
console.log("Account state hash in header: "+ledger.ledger_json.account_hash);
console.log("Calculated account state hash: "+ledger.calc_account_hash().to_hex());