+0
Daily
9,512
stars
1,156
forks
199
watchers
870
prs
581
issues
18
releases
README
CFSSL CloudFlare's PKI/TLS toolkit CFSSL is CloudFlare's PKI/TLS swiss army knife. It is both a command line tool and an HTTP API server for signing, verifying, and bundling TLS certificates. It requires Go 1.27+ to build. Note that certain linux distributions have certain algorithms removed (RHEL-based distributions in particular), so the golang from the official repositories will not work. Users of these distributions should install go manually to install CFSSL. CFSSL consists of: a set of packages useful for building custom TLS PKI tools the cfssl program, which is the canonical command line utility using the CFSSL packages. the multirootca program, which is a certificate authority server that can use multiple signing keys. the mkbundle program is used to build certificate pool bundles. the cfssljson program, which takes the JSON output from the cfssl and multirootca programs and writes certificates, keys, CSRs, and bundles to disk. Building Building cfssl requires a working Go 1.27+ installation. $ git clone [email protected]:cloudflare/cfssl.git $ cd cfssl $ make $ make install The resulting binaries will be in the bin folder: $ tree bin bin ├── cfssl ├── cfssl-bundle ├── cfssl-certinfo ├── cfssl-newkey ├── cfssl-scan ├── cfssljson ├── mkbundle └── multirootca 0 directories, 8 files Cross Compilation You can set the GOOS and GOARCH environment variables to have Go cross compile for alternative platforms; however, cfssl requires cgo, and cgo requires a working compiler toolchain for the target platform. Installation Installation requires a working Go 1.27+ installation. Alternatively, prebuilt binaries are available $ go install github.com/cloudflare/cfssl/cmd/...@latest This will download, build, and install all of the utility programs (including cfssl, cfssljson, and mkbundle among others). Using the Command Line Tool The cfssl command line tool takes a command to specify what operation it should carry out: sign signs a certificate bundle build a certificate bundle genkey generate a private key and a certificate request gencert generate a private key and a certificate serve start the API server version prints out the current version selfsign generates a self-signed certificate print-defaults print default configurations Use cfssl [command] -help to find out more about a command. The version command takes no arguments. Signing cfssl sign [-ca cert] [-ca-key key] [-hostname comma,separated,hostnames] csr [subject] The csr is the client's certificate request. The -ca and -ca-key flags are the CA's certificate and private key, respectively. By default, they are ca.pem and ca_key.pem. The -hostname is a comma separated hostname list that overrides the DNS names and IP address in the certificate SAN extension. For example, assuming the CA's private key is in /etc/ssl/priv
Top issues
#657policy violation error when creating intermediate CA with profile intermediate18 comments · 2016-08-19#965Certificate serial stored as Decimal instead of Hex 17 comments · 2019-01-23#624`Unknown private key error` when using a remote auth config 14 comments · 2016-06-30#599Unable to set multiple OUs in the "names" field13 comments · 2016-04-20#604Revoking certs through the API12 comments · 2016-04-22#563Secure CA private key storage12 comments · 2016-03-25#1023Support for configurable TLS ciphers8 comments · 2019-08-02#854cfssl authsign - "json: cannot unmarshal object into Go value of type []uint8"8 comments · 2018-02-13
Latest release
v1.7.1 v1.7.1 2026-10-06Changelog ab47f0d984778865b3f5b5adf6ba336a15b96c31 Merge pull request 1450 from upodroid/k8s-arches f26318e529daed741c4d24d8c0fae0270d1435eb build releases for riscv64 and ppc64le