Skip to content

security(block-producer): allowlist device_info on public /block/producers (keep endpoints public)#6755

Merged
Scottcjn merged 1 commit into
mainfrom
security/public-endpoints-safe
Jun 1, 2026
Merged

security(block-producer): allowlist device_info on public /block/producers (keep endpoints public)#6755
Scottcjn merged 1 commit into
mainfrom
security/public-endpoints-safe

Conversation

@Scottcjn
Copy link
Copy Markdown
Owner

@Scottcjn Scottcjn commented Jun 1, 2026

Per the decision to keep /block/slot, /block/producers, /api/wallet public (PoA consensus transparency; explorer/dashboard depend on them; no secrets exposed), this applies the one safe hardening from tri-brain review: device_info is exposed via an explicit field allowlist so a future column (e.g. an IP/hostname) can't leak through the unauthenticated endpoint. Output is unchanged for current data; non-dict rows degrade to {} instead of 500. is_my_turn + balance summary kept intact (no API-contract break). 4 producer tests green. Supersedes #6715 (which admin-gated these and would break the explorer).

🤖 Generated with Claude Code

…ucers

Per Scott's call, /block/slot, /block/producers, and /api/wallet stay PUBLIC
(proof-of-antiquity consensus transparency the explorer/dashboard depend on;
no secrets/IPs/keys are exposed). The only hardening kept after tri-brain review:
expose device_info through an explicit field allowlist
(arch/family/model/year/enroll_weight) so a future column added to device_info
(e.g. an IP/hostname) can never leak through this unauthenticated endpoint.
Output is unchanged for current data; a non-dict/None row degrades to {} instead
of raising. is_my_turn and the balance summary are intentionally left as-is to
avoid breaking the public API contract.

Supersedes #6715 (which admin-gated these public endpoints and would have broken
the explorer). Tri-brain reviewed (Codex/Grok; GPT-OSS offline) — earlier
over-broad changes (removing is_my_turn, capping balance) were reverted as
regressions.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@Scottcjn Scottcjn merged commit 8e535f3 into main Jun 1, 2026
@Scottcjn Scottcjn deleted the security/public-endpoints-safe branch June 1, 2026 19:41
@github-actions github-actions Bot added BCOS-L1 Beacon Certified Open Source tier BCOS-L1 (required for non-doc PRs) node Node server related size/S PR: 11-50 lines labels Jun 1, 2026
@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented Jun 1, 2026

✅ BCOS v2 Scan Results

Metric Value
Trust Score 60/100
Certificate ID BCOS-85825b91
Tier L1 (met)

BCOS Badge

What does this mean?

The BCOS (Beacon Certified Open Source) engine scans for:

  • SPDX license header compliance
  • Known CVE vulnerabilities (OSV database)
  • Static analysis findings (Semgrep)
  • SBOM completeness
  • Dependency freshness
  • Test infrastructure evidence
  • Review attestation tier

Full report | What is BCOS?


BCOS v2 Engine - Free & Open Source (MIT) - Elyan Labs

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/S PR: 11-50 lines

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants