From f72bb03af6d7f06a5d3fc911c806662ff0b4cd36 Mon Sep 17 00:00:00 2001 From: SomberNight Date: Sat, 2 Nov 2019 05:46:52 +0100 Subject: [PATCH] commands: gettransaction cmd now tests txid before returning tx thanks for @JeremyRand ref #5660 --- electrum/commands.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/electrum/commands.py b/electrum/commands.py index c06cc6126..01a8841ac 100644 --- a/electrum/commands.py +++ b/electrum/commands.py @@ -701,6 +701,8 @@ class Commands: tx = Transaction(raw) else: raise Exception("Unknown transaction") + if tx.txid() != txid: + raise Exception("Mismatching txid") return tx.as_dict() @command('')