bxp acme issue¶
Get a TLS certificate.
Usage¶
Get a TLS certificate for this machine.
How the proof works: the CA connects to each host name, and this
command answers. With --challenge http-01 (the default) the CA sends
an HTTP request to port 80; with tls-alpn-01 it opens a TLS connection
to port 443. So run it on the machine the names point to, with that
port free and reachable from the CA. Ports below 1024 usually need root.
(dns-01, which wildcard names need, is answered in your DNS: use an
ACME client with a plugin for your DNS provider, such as lego or certbot.)
The CA only issues for names in the domains its administrator has
allowed. It writes the same files as "bxp tls":
<name>.key the private key (it never leaves this machine)
<name>.crt the certificate, followed by the intermediate certificate
It also keeps an account key (acme-account.key). Keep that file: the
next request uses it again.
Usage:
bxp acme issue [flags]
Examples:
sudo bxp acme issue --ca-url https://ca.example.com:8443 --root root.crt \
--name web.example.com
Flags:
--account-key string file with the ACME account key; created if missing (default: acme-account.key in --out-dir)
--challenge string how to prove the names: http-01 (port 80) or tls-alpn-01 (port 443) (default "http-01")
--force replace the key and certificate files if they exist
-h, --help help for issue
--http-address string where to listen for http-01. The CA always asks on port 80,
so another port only works if something forwards port 80 to it (default ":80")
--name stringArray a host name or IP address for the certificate (repeat for more)
--out-dir string directory to write the key and certificate to (default ".")
--tls-address string where to listen for tls-alpn-01. The CA always connects to port 443,
so another port only works if something forwards port 443 to it (default ":443")
Global Flags:
--ca-url string address of the CA server, e.g. https://ca.example.com:8443
(or BXP_CA_URL; default: the one saved by "bxp trust")
--config string path to the configuration file (default "bastionxp-ca.yaml")
--directory string address of the ACME directory of another CA, e.g. https://acme-v02.api.letsencrypt.org/directory
(default: the one of the server given with --ca-url). The CA's certificate is
checked against --root, or against the system's roots
--root string path of the CA's root certificate, root.crt
(or BXP_ROOT; default: the one saved by "bxp trust")
Parent command: bxp acme