Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
24 commits
Select commit Hold shift + click to select a range
99ab18f
release-tools: add openssl-pgp wrapper
quarckster May 7, 2026
3b9a73f
release-tools: add sq-pkcs11-git-shim
quarckster May 7, 2026
53fa859
stage-release.sh: --gpg-program option for tag signing
quarckster May 7, 2026
f455ceb
release-tools/openssl-pgp: subkey-revoke takes --subkey-fingerprint
quarckster May 7, 2026
d26538f
release-tools/openssl-pgp: gate sign on cert-bound signing-key check
quarckster May 7, 2026
f0a0795
release-tools: add openssl-pgp-ceremony-run
quarckster May 9, 2026
a48214e
release-tools/openssl-pgp-ceremony-run: add tmux start-and-wait orche…
quarckster May 9, 2026
cdfa615
release-tools/openssl-pgp: run generatekey in batch mode
quarckster May 9, 2026
e89cf28
release-tools: add openssl-pgp-revocation-recipients bundle helper
quarckster May 11, 2026
0e99f09
release-tools/openssl-pgp-ceremony-run: skip server owner in access g…
quarckster May 11, 2026
dbb9f02
openssl-pgp: route OCS quorum operations through preload
quarckster May 11, 2026
fb98905
openssl-pgp: pin preload to module 1 by default
quarckster May 11, 2026
cc5708e
stage-release.sh: route all signing through openssl-pgp
quarckster May 13, 2026
eb7d738
stage-release.sh: drop unused CLI flags and upload machinery
quarckster May 13, 2026
4dc2a1a
stage-release.sh: drop announcement file, quiet copyright spinner
quarckster May 13, 2026
ce8e4f7
stage-release.sh: hardcode signers, drop --gpg-program
quarckster May 13, 2026
0893ac8
stage-release.sh: drop --branch, always create release branch when ne…
quarckster May 13, 2026
680fab6
stage-release.sh: rename --local-user to --key-label
quarckster May 14, 2026
4b4f868
release-tools: derive signing creation time from the published cert
quarckster Jun 14, 2026
cc180d5
release-tools: drop tag signing from stage-release.sh
quarckster Aug 7, 2026
4c0795c
release-tools: drop the --unsigned option
quarckster Aug 7, 2026
213343f
openssl-pgp: drop the sign command
quarckster Aug 8, 2026
dc632c3
move the OpenPGP key-lifecycle tools out of release-tools
quarckster Aug 8, 2026
305ac89
openpgp-tools: add a README
quarckster Aug 8, 2026
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
60 changes: 60 additions & 0 deletions openpgp-tools/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,60 @@
# OpenPGP key-lifecycle tools

This directory contains the tools that manage the lifecycle of the OpenPGP key
used to sign OpenSSL release artifacts. The key material lives in an Entrust
nShield HSM (Security World); these scripts never touch private key bytes, they
only drive the nShield tooling and [`sq-pkcs11`](https://github.com/openssl/sq-pkcs11)
to produce OpenPGP certificates and revocation certificates.

## Contents

- `openssl-pgp` — the main driver. Implements the
[artifact signing policy](https://openssl-library.org/policies/general/artifact-signing-policy/)
on top of `sq-pkcs11` (which speaks PKCS#11 to the HSM) and the nShield
utilities (`generatekey`, `cklist`, `nfkminfo`, `preload`). Commands:

| Command | Purpose |
| --- | --- |
| `primary-generate` | generate the OCS-protected RSA-4096 primary key |
| `subkey-generate` | generate a module-protected RSA-4096 signing subkey |
| `cert-init` | issue the published certificate plus an offline primary revocation certificate |
| `subkey-rotate` | bind a new signing subkey into the published certificate |
| `cert-revoke` | issue a primary-key revocation certificate |
| `subkey-revoke` | revoke a subkey by fingerprint, using only the primary key |

Configuration comes from environment variables (`OPENSSL_PGP_*`), optionally
sourced from a config file — `$OPENSSL_PGP_CONFIG`, or `openssl-pgp.conf`
next to the script. Run `openssl-pgp --help` for the full list.

Policy enforced by the script: RSA-4096 keys, `logkeyusage=yes` for Security
World audit logging, primary protected by the configured K/N OCS with 5y
validity, signing subkeys module-protected with 1y validity, and certificate
timestamps derived from the nShield `gentime` rather than the wall clock.
Labels and cardsets are validated against the Security World before any
destructive HSM action runs.

- `openssl-pgp-ceremony-run` — runs an attended OCS ceremony from an automation
server without ever routing card passphrases through it. It starts the
requested `openssl-pgp` command in a detached `tmux` session on the HSM
client and waits for its exit status; custodians SSH to that host, attach to
the session, present their cards and type OCS passphrases directly into the
shared terminal. The automation server stays an orchestrator and audit
collector only.

- `openssl-pgp-revocation-recipients` — validates the revocation-certificate
recipients and produces an encryption bundle: it checks each recipient
certificate's fingerprint, User ID email, and usability under the current `sq`
policy, then emits a concatenated certificate bundle, a recipient manifest,
and the bundle's SHA-256 checksum.

- `revocation-recipients/` — the recipient set consumed by the above:
`recipients.txt` (the authoritative `<fingerprint> <email>` manifest) and one
`<fingerprint>.pgp` public certificate per entry. See the README in that
directory.

## Requirements

- [`sq-pkcs11`](https://github.com/openssl/sq-pkcs11) on `PATH` (or
`OPENSSL_PGP_SQ_PKCS11` pointing at it), plus `sq` for the recipient tooling.
- nShield client tooling under `/opt/nfast` and access to the Security World.
- `tmux` on the HSM client, for `openssl-pgp-ceremony-run`.
Loading