[VPD-1247]: Hashdit Audit Mitigations for PrimeV2#674
Open
Debugger022 wants to merge 12 commits into
Open
Conversation
There was a problem hiding this comment.
Claude Code Review
This repository is configured for manual code reviews. Comment @claude review to trigger a review and subscribe this PR to future pushes, or @claude review once for a one-time review.
Tip: disable this comment in your organization's Code Review settings.
Contributor
|
changes LGTM |
Contributor
|
lgtm |
fred-venus
approved these changes
May 25, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Changes
PrimeLeaderboardStorage:__gap[48] → __gap[45](50-slot convention).PrimeV2.removeMarket: drop redundant_queueScoreUpdates()(precondition guarantees zero score impact; was clobbering in-flight rounds).PrimeV2.setMintThreshold: reject non-zero pastmintDeadline_(InvalidDeadline).PrimeLeaderboard.xvsUpdated: applynonReentranton the only external-call surface.PrimeLeaderboard.initializeStakers: rejectts == 0 || ts > block.timestamp(InvalidTimestamp).PrimeV2.addMarket: restore V1's post-push_ensureMaxLoops(_allMarkets.length).PrimeV2.issue/issueBatch: reject zero-address (matchesclaimPrime).Test plan
yarn hardhat compile— cleanyarn hardhat test tests/hardhat/PrimeV2/— 191 passingremoveMarketno longer wipes legitimate in-flight roundsaddMarketreverts atomically when listing would exceedloopsLimit