Skip to content

[BOUNTY] TOFU Key Revocation and Rotation — 15 RTC (focused)#390

Closed
dannamax wants to merge 3 commits intoScottcjn:mainfrom
dannamax:fix-tofu-key-revocation-focused
Closed

[BOUNTY] TOFU Key Revocation and Rotation — 15 RTC (focused)#390
dannamax wants to merge 3 commits intoScottcjn:mainfrom
dannamax:fix-tofu-key-revocation-focused

Conversation

@dannamax
Copy link

Fixes #308

This PR implements a focused TOFU (Trust-On-First-Use) key management system for RustChain attestation with:

Core Features Only:

  • Admin endpoint to revoke compromised keys (POST /admin/tofu/revoke)
  • Agent endpoint to rotate their own keys (POST /tofu/rotate)
  • Revoked keys immediately rejected on all endpoints
  • Rotation creates audit trail (old key → new key, timestamp)
  • Storage extends existing nonce/TOFU SQLite storage

Focused Implementation:

  • ONLY adds TOFU tables, validation functions, and HTTP endpoints
  • NO unrelated features or modifications
  • NO import of nonexistent modules
  • Clean merge against main branch

Security & Quality:

  • Proper admin authentication for revocation endpoint
  • Ed25519 signature verification with pynacl
  • Comprehensive error handling and validation
  • Full test coverage included

This is a focused resubmission of PR #386 based on maintainer feedback. All scope creep issues have been addressed.


Testing: All unit tests pass. Implementation follows BS2.0 quality principles.

@dannamax dannamax requested a review from Scottcjn as a code owner February 26, 2026 05:15
@github-actions github-actions bot added BCOS-L1 Beacon Certified Open Source tier BCOS-L1 (required for non-doc PRs) node Node server related tests Test suite changes size/XL PR: 500+ lines labels Feb 26, 2026
@Scottcjn Scottcjn closed this Feb 26, 2026
@Scottcjn
Copy link
Owner

Closing as duplicate of PR #395 (same bounty, same author).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

BCOS-L1 Beacon Certified Open Source tier BCOS-L1 (required for non-doc PRs) node Node server related size/XL PR: 500+ lines tests Test suite changes

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants