Skip to content

Guard transaction replay height overflow#440

Open
giwaov wants to merge 1 commit into
canopy-network:mainfrom
giwaov:issue-transaction-height-overflow-guard
Open

Guard transaction replay height overflow#440
giwaov wants to merge 1 commit into
canopy-network:mainfrom
giwaov:issue-transaction-height-overflow-guard

Conversation

@giwaov

@giwaov giwaov commented Jun 28, 2026

Copy link
Copy Markdown

Summary

  • Saturate the maximum accepted replay height when the current height is near max uint64.
  • Prevent unsigned wraparound from rejecting otherwise valid transaction heights.
  • Add a regression case for near-max replay height bounds.

Why

CheckReplay calculated height + BlockAcceptanceRange directly. Near max uint64, that addition can wrap to a small value and make a same-height transaction fail the upper-bound check.

Testing

  • git diff --check
  • Not run: Go toolchain is not installed in this environment.

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.

1 participant