Skip to content

feat(core): implement transaction signature verification and reject duplicates#544

Merged
MicaiahReid merged 2 commits intomainfrom
fix/tx-dedup
Mar 5, 2026
Merged

feat(core): implement transaction signature verification and reject duplicates#544
MicaiahReid merged 2 commits intomainfrom
fix/tx-dedup

Conversation

@MicaiahReid
Copy link
Copy Markdown
Collaborator

No description provided.

@MicaiahReid MicaiahReid requested a review from lgalabru March 3, 2026 19:24
Copy link
Copy Markdown
Collaborator

@lgalabru lgalabru left a comment

Choose a reason for hiding this comment

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

Per @Aursen, this behavior is by default implemented in LiteSVM. Could we please add a comment explaining why we had to disable it?

@MicaiahReid
Copy link
Copy Markdown
Collaborator Author

Per @Aursen, this behavior is by default implemented in LiteSVM. Could we please add a comment explaining why we had to disable it?

I wanted the same thing, but tbh I couldn't find our reasoning...
I remember it causing issues in the past, but I don't remember the cause and couldn't find issues relating to it.

I was worried about the issue arising again if I enabled it blindly.

I did some digging again and I have a possible reason: the LiteSVM sigverify being set to true will verify transaction simulations as well as actual transaction processing. So we'd have to temporarily disable in the svm.rs file via:

fn simulate_transaction(&self, sigverify: bool) ... {
if !sigverify {
   self.sigverify(false);
}

/// simulate

// reset it for future tx processing
if !sigverify {
    self.sigverify(true);
}

which would also force simulate_transaction to require &mut self, and seems odd to have mutable vm for a simulate endpoint.

Don't know if that's a strong enough reason to have this extra code to maintain, though.

@MicaiahReid MicaiahReid merged commit fb12d84 into main Mar 5, 2026
5 checks passed
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