Skip to content

fix: correct docs and add keygen script#20

Merged
TeoSlayer merged 4 commits into
mainfrom
fix/docs-and-keygen
Jun 23, 2026
Merged

fix: correct docs and add keygen script#20
TeoSlayer merged 4 commits into
mainfrom
fix/docs-and-keygen

Conversation

@TeoSlayer

Copy link
Copy Markdown
Contributor

Fixes README IsTrusted return type, updates misleading package comment, adds -ldflags injection instructions, adds scripts/gen-signing-key.sh.

Changes

  • README.md: corrected IsTrusted(nodeID) return type from (description, ok) to (hostname, ok) to match the actual function signature.
  • data.go: replaced the inaccurate "no separate signature check" package comment with an accurate two-tier description — unsigned lists accepted over TLS with a warning; signed lists require Ed25519 verification via VerifyAndStripSig.
  • data.go: added -ldflags injection comment near embeddedPubKey showing how to supply the real key at build time and pointing to the new keygen script.
  • scripts/gen-signing-key.sh: new executable script that uses go run with inline Go code to generate an ed25519 keypair and print both the secret private key and the hex public key ready for -ldflags injection.

teovl and others added 2 commits June 19, 2026 09:30
@codecov

codecov Bot commented Jun 21, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.

📢 Thoughts on this report? Let us know!

@TeoSlayer

Copy link
Copy Markdown
Contributor Author

Clean / CI green. Adds a signing-key generator script + doc fixes. Low-risk to merge. Quick check before merging: confirm the script only generates a keypair locally and never commits or prints private material, and that the docs point at the keyring-pin workflow.

teovl added 2 commits June 23, 2026 16:17
… public material

The script previously echoed the Ed25519 private key (hex) to stdout, exposing
it to the terminal, shell history, and CI logs. Write the private key to a
0600 file instead (default ./signing-key.hex, or an operator-supplied path)
and print only public material: the public key in hex (for the
embeddedPubKeyHex ldflags) and in std-base64 (for the per-entry public_key
pin in trusted-agents.json).

Refuse to overwrite an existing key file, create the file with a tight umask
before writing any secret, and gitignore signing-key.hex and *.key so the
private key can never be committed.
@TeoSlayer TeoSlayer merged commit 8d0db5d into main Jun 23, 2026
13 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants