fix: harden attestation signing fallback#6868
Conversation
1b04231 to
504cf09
Compare
|
Validation update after rebasing on current main and syncing the fetchall baseline line drift:
CI is green on the updated head. |
|
This is a clean, complete follow-up to #6859 — thank you. I verified it addresses all three items:
Also verified: the checksum manifest matches the actual miner files (no stale-manifest issue), and it's only 2 commits behind main. The signing algorithm is unchanged from the verified #6839 fix — this is purely the hardening/distribution/logging/test layer — so no fresh crypto review needed. One thing holding the green check: |
504cf09 to
224578b
Compare
jaxint
left a comment
There was a problem hiding this comment.
Thanks for the contribution! 🎉
JesusMP22
left a comment
There was a problem hiding this comment.
Code Review: Harden attestation signing fallback
Summary: Improves the robustness of attestation signing by hardening the fallback mechanism, ensuring miners can still attest even when primary signing fails.
What I like:
- Fallback mechanisms are critical for system reliability
- Attestation is core to RustChain's trust model
Suggestions:
- Document the fallback signing path and its security properties
- Add tests that simulate primary signing failure and verify fallback works
- Consider whether fallback signatures should be distinguishable from primary ones
- Ensure the fallback doesn't introduce a weaker security guarantee
Security considerations:
- Fallback paths are often where security weaknesses hide
- Ensure the fallback signing key has the same protection as the primary
- Consider whether fallback could be exploited to submit fraudulent attestations
Verdict: ✅ Good reliability improvement. Fallback hardening is important for production systems.
jaxint
left a comment
There was a problem hiding this comment.
Great work! Thanks for contributing.
jaxint
left a comment
There was a problem hiding this comment.
Thanks for the contribution! 🎉
jaxint
left a comment
There was a problem hiding this comment.
Thanks for this contribution! Great work.
Summary
Fixes #6859 by hardening the attestation-signing follow-ups from the #6839 review.
What changed:
setup_miner.pynow downloads and SHA-256 verifiesminers/signing_helpers.pynext to the installed miner, so installed Linux/Windows miners can use the shared pipe-message builder instead of always taking the inline fallback.signing_helpers.pyviaminers/checksums.sha256.LocalMiner.attest()with_SIGNING_HELPERS=Falseand asserting the signed bytes match the node verifier reconstruction (miner_id|miner|nonce|commitment).Scope notes
Validation
Bounty / payout
Wallet:
RTCf69dd944558d4e843a4a676495a97638055caea2