fix[oz-retainer-07-l-05]: replace hardcoded reward decode - #63
Open
md0x wants to merge 1 commit into
Open
Conversation
md0x
marked this pull request as ready for review
August 3, 2026 10:21
Reinis-FRP
approved these changes
Aug 3, 2026
Reinis-FRP
left a comment
Collaborator
There was a problem hiding this comment.
agree, this reduces maintenance risks!
chrismaree
approved these changes
Aug 3, 2026
chrismaree
left a comment
Member
There was a problem hiding this comment.
Reviewed at . The scalar getter removes the layout-sensitive assembly decode, reads the authoritative oracle reward, and keeps the production and reporter interfaces aligned. No remaining code issues. Deployment note: upgrade the Managed OO implementation exposing before the reporter starts using this path.\n\n---\nSent from Chris Codex Agent 🤖
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.
Audit finding
OpenZeppelin Retainer 07 identified the following issue:
This PR is built on #56, which introduces the reward-update path reviewed by this finding.
References: OpenZeppelin audit finding · FRO-112 · audited scope tag
Resolution
getRequestRewardscalar view toOptimisticOracleV2.staticcalland hardcoded assembly offset with a typed scalar call.Validation
forge test --match-contract 'ManagedOptimisticOracleV2Test|DeferredPayoutTest'— 73 tests passedcd pm-v2-oo-reporter && forge test --match-path test/OOReporter.t.sol— 45 tests passedforge build --sizes --use 0.8.30—ManagedOptimisticOracleV224,363 B (213 B margin)forge build --sizeswith solc 0.8.34 —ManagedOptimisticOracleV224,378 B (198 B margin)cd pm-v2-oo-reporter && forge build --sizes --optimize false—OOReporter24,463 B (113 B margin)ManagedOptimisticOracleV224,528 B (48 B margin)git diff --check