# `mix countersign.gen.seal_keys`
[🔗](https://github.com/mkreyman/countersign/blob/v0.1.0/lib/mix/tasks/countersign.gen.seal_keys.ex#L1)

Writes two self-signed certificates and their PKCS #8 private keys, one
Ed25519 and one SLH-DSA, as PEM files `Countersign.Seal.Cert.from_pem/2`
reads back:

    $ mix countersign.gen.seal_keys --out ~/seal_keys --subject "Acme Care seal" --org "Acme Care"

writes `ed25519_cert.pem`, `ed25519_key.pem`, `slh_dsa_cert.pem` and
`slh_dsa_key.pem` into the output directory, the keys with mode 0600.
Keep the keys out of version control: put their contents in the host's
secret store and delete the files.

## Options

  * `--out` - the directory to write into (required): pick one outside the
    project, since a key under `priv/` is committed and ships in a release
  * `--subject` - the certificates' common name (default `Countersign seal`)
  * `--org` - an organization for the certificates' subject
  * `--variant` - the SLH-DSA parameter set, as its OTP name (default
    `slh_dsa_sha2_192s`)
  * `--years` - how long the certificates are valid (default 10)

Refuses to overwrite a file that exists, and stops when this OTP cannot
sign with the SLH-DSA set (`:crypto.supports(:public_keys)`).

---

*Consult [api-reference.md](api-reference.md) for complete listing*
