vtnerd / monero-lws

Monero Light Wallet Server (scans monero viewkeys and implements mymonero API). Fast LMDB backend.
BSD 3-Clause "New" or "Revised" License
78 stars 29 forks source link

Fix spend tracking bug in db::storage #89

Closed vtnerd closed 12 months ago

vtnerd commented 1 year ago

I found another bug when writing unit tests - if there are multiple valid entries in a ring only one is tracked due to the DB sorting algorithm. #87 confirms the fix. I decided to put this in a separate PR to make it easier to backport into the release branch.

Hitting this case is extremely rare, you'd have to select your own output as a decoy in a ring, then have that decoy take precendence in the sorting algorithm over the real spend.