Skip to content

fix: clear stale exn escrows after signature check to avoid race conditions - #10

Merged
AABelkhiria merged 3 commits into
release/v1.3-idwfrom
fix/clear-stale-partially-signed-exchanges
Jul 23, 2026
Merged

fix: clear stale exn escrows after signature check to avoid race conditions#10
AABelkhiria merged 3 commits into
release/v1.3-idwfrom
fix/clear-stale-partially-signed-exchanges

Conversation

@AABelkhiria

@AABelkhiria AABelkhiria commented Jul 23, 2026

Copy link
Copy Markdown

Exn escrows have a short, 10 second timeout to clear. Currently, the signatures are not being cleared properly from the database. As a result, other signatures can arrive after the 10 second limit and the exn will verify.

However, if the final threshold signature arrives right as the previous escrow is being timed out, we lose the escrow, despite the database having sufficient signatures.

The fix: Time out escrows after checking the signature threshold count. A better long term solution would be to increase the escrow timeout to better reflect human activity in groups, but for now this is a safer option.

@AABelkhiria AABelkhiria changed the title fix: clear stale partially signed exchange escrows fix: clear stale exn escrows after signature check to avoid race conditions Jul 23, 2026

@iFergal iFergal left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Unsure why macos-15 is failing

@iFergal

iFergal commented Jul 23, 2026

Copy link
Copy Markdown
Collaborator

Sorry, yes, failing due to libsodium now (already forgot from before lunch lol)

@AABelkhiria

Copy link
Copy Markdown
Author

yep
I was testing using act not to spam the commits and actions in here.
I will be pushing the "fix" now

@AABelkhiria
AABelkhiria merged commit bebbbea into release/v1.3-idw Jul 23, 2026
6 checks passed
@AABelkhiria
AABelkhiria deleted the fix/clear-stale-partially-signed-exchanges branch July 23, 2026 12:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants