[bisq-network/bisq] Add irregular txType, add check for total balance, prevent proposal withhold attack (#2587)

sqrrm notifications at github.com
Sat Mar 30 20:55:58 UTC 2019


sqrrm commented on this pull request.



> @@ -811,6 +816,27 @@ public long getTotalAmountOfConfiscatedTxOutputs() {
                 .sum();
     }
 
+    public long getBurnedBsqOfAllInvalidTxs() {
+        return getTxStream()
+                .filter(e -> e.getTxType() == TxType.INVALID)
+                .mapToLong(this::getBurnedBsqOfInvalidTx)
+                .sum();
+    }
+
+    public long getBurnedBsqOfInvalidTx(Tx tx) {

Yes, my point was that the function can calculate the input value from any tx, not only invalid ones.

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/bisq-network/bisq/pull/2587#discussion_r270641511
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.bisq.network/pipermail/bisq-github/attachments/20190330/f3b79576/attachment.html>


More information about the bisq-github mailing list