Craton HSM
Enterprise Overview
Enterprise Overview
Craton HSM Enterprise is a source-available add-on bundle that sits on top of the Apache-2.0 core. It supplies the pieces a production HSM deployment needs that are out of scope for the core library: FIPS-validated crypto, vendor hardware backends, enterprise identity, multi-node replication, KMIP, cloud integrations, and FIPS 140-3 certification tooling.
Enterprise is distributed under the Business Source License 1.1. Each version automatically converts to Apache-2.0 four years after release, or on 2030-03-13, whichever comes first.
What Enterprise Adds
Every Enterprise crate implements or composes with the CryptoBackend trait
defined in craton-hsm-core. Application code stays backend-agnostic:
swapping RustCryptoBackend for AwsLcBackend buys FIPS validation, and
swapping it for Pkcs11PassthroughBackend pushes key material into a
hardware token.
Apache-2.0 core
+----------------------+
| craton-hsm |
| CryptoBackend trait |
| PKCS#11 ABI, audit |
+----------+-----------+
|
+-----------------------+---------------------+
| | |
Software backends Hardware backends Enterprise services
(BSL 1.1) (BSL 1.1, `hw`) (BSL 1.1)
- craton-hsm-awslc - craton-hsm-nxp - craton-hsm-auth
- craton-hsm-openssl - craton-hsm-infineon - craton-hsm-cluster
- craton-hsm-cng - craton-hsm-pkcs11 - craton-hsm-kmip
- craton-hsm-cloud
- craton-hsm-certified
Crate Matrix
| Crate | Role | Default build | Hardware / external dep |
|---|---|---|---|
craton-hsm-awslc | FIPS-validated software crypto via aws-lc-rs | Available | Go 1.21+ at build time for fips feature |
craton-hsm-openssl | Non-FIPS crypto over system OpenSSL 3 | Available | OpenSSL 3.x headers and libraries |
craton-hsm-cng | Windows CNG / BCrypt crypto, FIPS-dispatch mode | Available (Windows only) | Windows 10 / Server 2016 or newer |
craton-hsm-pkcs11 | Passthrough to vendor PKCS#11 tokens | Available | Vendor PKCS#11 .so / .dll |
craton-hsm-auth | RBAC, LDAP, cert, MFA, OIDC, tenants, dual-control | Available | Optional per-provider features |
craton-hsm-cluster | Raft consensus, replication, snapshots, health | Available | Tokio runtime, fsync-capable FS |
craton-hsm-kmip | KMIP 1.4-subset server, TTLV codec | Available | TLS terminator with mTLS |
craton-hsm-cloud | Kubernetes CSI, AWS/Azure/Vault shims | Reference / mock | Double opt-in for mock backends |
craton-hsm-nxp | NXP HSE backend for S32G / S32K3 | Available (stub without hw) | NXP HSE SDK for hw feature |
craton-hsm-infineon | Infineon SLB 9670 / 9672 TPM 2.0 backend | Available (stub without hw) | libtss2-esys 4.0+ for hw feature |
craton-hsm-certified | Reproducible builds, CMVP artifacts, ACVP harness | Available | NIST ACVP vectors (external) |
See the compatibility matrix for tested OS, toolchain, and vendor library versions.
Build and Feature-Flag Model
All Enterprise crates share a single Cargo workspace and a common MSRV of Rust 1.75. The crates pull the core library in as a sibling directory; clone both repositories side by side:
craton-hsm/
craton-hsm-core/ Apache-2.0, upstream
craton-hsm-enterprise/ BSL 1.1, this workspace
A default build is safe to run end-to-end against software crypto:
cargo build --workspace
cargo test --workspace
cargo clippy --workspace -- -D warnings
Feature flags opt into functionality that has external dependencies, extra runtime cost, or deliberate operational risk. The full feature surface is:
| Crate | Feature | Purpose |
|---|---|---|
craton-hsm-awslc | fips | Build aws-lc-rs in FIPS mode (needs Go 1.21+) |
craton-hsm-auth | ldap-auth | LDAP / Active Directory provider |
craton-hsm-auth | oidc-auth | OpenID Connect provider |
craton-hsm-auth | cert-auth | X.509 client certificate provider |
craton-hsm-nxp | hw | Link NXP HSE host library, enable real HSE calls |
craton-hsm-infineon | hw | Link libtss2-esys, enable real TPM 2.0 calls |
craton-hsm-cloud | mock-insecure-do-not-ship | Expose in-memory mock backends (testing only) |
craton-hsm-kmip | insecure-static-token | Single-token KMIP auth (testing only) |
craton-hsm-cluster | insecure-no-cluster-secret | Build a cluster node without an HMAC key (testing only) |
The insecure-* and mock-* features are double-gated: they require both
the compile-time feature and an environment variable
(CRATON_HSM_ALLOW_INSECURE_STATIC_TOKEN=1 or CRATON_HSM_ALLOW_MOCK=1) at
process start, so an accidentally-featured binary still refuses to run in
insecure mode.
When to Choose Enterprise
Pick Enterprise when any of the following apply:
- You need FIPS 140-3 validation, or you build for a market that requires
it.
craton-hsm-awslcwith thefipsfeature is the intended FIPS boundary. - You need an enterprise identity provider: LDAP / Active Directory, OIDC, mTLS-based client-cert auth, MFA, or dual-control for destructive operations.
- You want multi-tenant key isolation with per-tenant quotas.
- You deploy an HA cluster and need Raft-based key replication, snapshots, and authenticated inter-node RPCs.
- You need a KMIP endpoint so existing clients can use Craton HSM without code changes.
- You run on Kubernetes and want a CSI driver, or you are integrating with AWS KMS / Azure Key Vault / HashiCorp Vault surfaces.
- You target a vendor HSM (Thales Luna, Entrust nShield, AWS CloudHSM, YubiHSM, SoftHSM2) via PKCS#11, or embedded hardware (NXP HSE, Infineon TPM 2.0).
- You are preparing a CMVP submission and need the reproducible-build,
ACVP harness, and binary-signing tooling that lives in
craton-hsm-certified.
If none of those apply, the Apache-2.0 core alone is sufficient, and avoids the BSL competing-use restriction.
Status Summary
- Production-ready:
craton-hsm-awslc(with and withoutfips),craton-hsm-openssl,craton-hsm-cng,craton-hsm-pkcs11,craton-hsm-auth,craton-hsm-cluster,craton-hsm-kmip,craton-hsm-certified. - Pre-release hardware backends:
craton-hsm-nxpandcraton-hsm-infineon. The stub builds (default) are stable; thehwfeature has not been validated end-to-end against production firmware. - Reference / mock:
craton-hsm-cloud. The in-tree implementations are mocks behind a double opt-in. Production deployments are expected to re-implement the public traits against real transport stacks.
Related Documents
- Licensing — BSL 1.1 in practice, commercial licensing.
- FIPS certification plan — CMVP roadmap.
- Compatibility matrix — tested versions.