Skip to content

security(hsm): move X25519 ECDH into PKCS#11 and enable full in-token…#22

Merged
doomhammerhell merged 1 commit into
mainfrom
X25519intoPKCS#11
Apr 27, 2026
Merged

security(hsm): move X25519 ECDH into PKCS#11 and enable full in-token…#22
doomhammerhell merged 1 commit into
mainfrom
X25519intoPKCS#11

Conversation

@doomhammerhell
Copy link
Copy Markdown
Owner

… hybrid decrypt

  • Extend HSM boundary with optional token-resident X25519 identity and “full in-token” decrypt mode
  • Implement PKCS#11 hybrid v1 decrypt path: KEM derive_key + ECDH1_DERIVE (EC_MONTGOMERY) + concat + HKDF + AES-GCM
  • Update GatewayHsmSecurityProvider to avoid host-held X25519 secrets when token provides X25519
  • Add provisioning example for generating/exporting X25519 public key from PKCS#11 token
  • Add regression test + document invariant: no silent fallback to exporting shared secrets

… hybrid decrypt

- Extend HSM boundary with optional token-resident X25519 identity and “full in-token” decrypt mode
- Implement PKCS#11 hybrid v1 decrypt path: KEM derive_key + ECDH1_DERIVE (EC_MONTGOMERY) + concat + HKDF + AES-GCM
- Update GatewayHsmSecurityProvider to avoid host-held X25519 secrets when token provides X25519
- Add provisioning example for generating/exporting X25519 public key from PKCS#11 token
- Add regression test + document invariant: no silent fallback to exporting shared secrets
@doomhammerhell doomhammerhell merged commit 99bb627 into main Apr 27, 2026
6 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.

1 participant