Skip to content

Commit

Permalink
maker: allow receiving more money than promised
Browse files Browse the repository at this point in the history
Fixes: #1709
  • Loading branch information
whitslack committed May 26, 2024
1 parent d117791 commit 861c790
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions src/jmclient/maker.py
Original file line number Diff line number Diff line change
Expand Up @@ -230,12 +230,12 @@ def verify_unsigned_tx(self, tx, offerinfo):
for outs in tx.vout:
if outs.scriptPubKey == cjaddr_script:
times_seen_cj_addr += 1
if outs.nValue != amount:
return (False, 'Wrong cj_amount. I expect ' + str(amount))
if outs.nValue < amount:
return (False, 'Wrong cj_amount. I expect >=' + str(amount))
if outs.scriptPubKey == changeaddr_script:
times_seen_change_addr += 1
if outs.nValue != expected_change_value:
return (False, 'wrong change, i expect ' + str(
if outs.nValue < expected_change_value:
return (False, 'Wrong change. I expect >=' + str(
expected_change_value))
if times_seen_cj_addr != 1 or times_seen_change_addr != 1:
fmt = ('cj or change addr not in tx '
Expand Down

0 comments on commit 861c790

Please sign in to comment.