PKI---ISSUE(1)
π pki --issue β issue a certificate using a CA certificate and key π
okay bestie, this is the PKI --ISSUE(1) page β strongSwan's pki --issue sub-command. It is literally the one that issues a certificate using a CA certificate and key, and it's giving main-character PKI energy. π
β¨ NAME β¨
pki --issue β issue a certificate using a CA certificate and key. periodt, that's the name, no cap.
πΈ SYNOPSIS πΈ
the shapes this command can take, bestie:
pki --issue [--in file] [--type type] --cakey file|--cakeyid hex
--cacert file [--dn subject-dn] [--san subjectAltName]
[--lifetime days] [--not-before datetime] [--not-
after datetime] [--serial hex] [--flag flag]
[--digest digest] [--rsa-padding padding] [--ca]
[--crl uri [--crlissuer issuer]] [--ocsp uri]
[--pathlen len] [--addrblock block] [--nc-permitted name]
[--nc-excluded name] [--critical oid]
[--policy-mapping mapping] [--policy-explicit len]
[--policy-inhibit len] [--policy-any len]
[--cert-policy oid [--cps-uri uri] [--user-notice text]]
[--outform encoding] [--debug level]
pki --issue --options file
pki --issue -h | --help
π¦ DESCRIPTION π¦
This sub-command of pki(1) is used to issue a certificate using a CA certificate and private key. slay β that's the whole assignment. π
π OPTIONS π
-h,--helpβ print usage information with a summary of the available options. ur welcome.-v,--debug levelβ set debug level, default:1.-+,--options fileβ read command line options fromfile. yes, the short option is literally-+, iconic.-i,--in fileβ public key or PKCS#10 certificate request file to issue. If not given, the key/request is read fromSTDIN.-t,--type typeβ type of the input. One ofpub(public key),priv(private key),rsa(RSA private key),ecdsa(ECDSA private key),ed25519(Ed25519 private key),ed448(Ed448 private key) orpkcs10(PKCS#10 certificate request), defaults topub.-k,--cakey fileβ CA private key file. Either this or--cakeyidis required.-x,--cakeyid hexβ smartcard or TPM CA private key object handle in hex format with an optional0xprefix. Either this or--cakeyis required.-c,--cacert fileβ CA certificate file. Required. no skipping this one, bestie.-d,--dn subject-dnβ subject distinguished name (DN) of the issued certificate.-a,--san subjectAltNameβ subjectAltName extension to include in certificate. Can be used multiple times. stack 'em.-l,--lifetime daysβ days the certificate is valid, default:1095. Ignored if both an absolute start and end time are given.-F,--not-before datetimeβ absolute time when the validity of the certificate begins. Thedatetimeformat is defined by the--dateformoption.-T,--not-after datetimeβ absolute time when the validity of the certificate ends. Thedatetimeformat is defined by the--dateformoption.-D,--dateform formβstrptime(3)format for the--not-beforeand--not-afteroptions, default:%d.%m.%y %T.-s,--serial hexβ serial number in hex. It is randomly allocated by default.-e,--flag flagβ add extendedKeyUsage flag. One ofserverAuth,clientAuth,crlSign,ocspSigningormsSmartcardLogon. Can be used multiple times. Without modifiers, this overrides flags from PKCS#10 certificate requests. Prefixing a flag with+adds it to the set of flags read from the request, prefixing it with-removes it from that set. the way that is so specific and so real.-g,--digest digestβ digest to use for signature creation. One ofmd5,sha1,sha224,sha256,sha384, orsha512. The default is determined based on the type and size of the signature key.-R,--rsa-padding paddingβ padding to use for RSA signatures. Eitherpkcs1orpss, defaults topkcs1.-f,--outform encodingβ encoding of the created certificate file. Eitherder(ASN.1 DER) orpem(Base64 PEM), defaults toder.-b,--caβ include CA basicConstraint extension in certificate.-u,--crl uriβ CRL distribution point URI to include in certificate. Can be used multiple times.-I,--crlissuer issuerβ optional CRL issuer for the CRL at the preceding distribution point.-o,--ocsp uriβ OCSP AuthorityInfoAccess URI to include in certificate. Can be used multiple times.-p,--pathlen lenβ set path length constraint.-B,--addrblock blockβ RFC 3779 address block to include in certificate.blockis either a CIDR subnet (such as10.0.0.0/8) or an arbitrary address range (192.168.1.7-192.168.1.13). Can be repeated to include multiple blocks. Please note that the supplied blocks are included in the certificate as is, so for standards compliance, multiple blocks must be supplied in correct order and adjacent blocks must be combined. Refer to RFC 3779 for details. this one is giving "read the RFC, bestie" energy.-n,--nc-permitted nameβ add permitted NameConstraint extension to certificate. For DNS or email constraints, the identity type is not always detectable by the given name. Use thedns:oremail:prefix to force a constraint type.-N,--nc-excluded nameβ add excluded NameConstraint extension to certificate. For DNS or email constraints, the identity type is not always detectable by the given name. Use thedns:oremail:prefix to force a constraint type.-X,--critical oidβ add a critical extension with the given OID.-M,--policy-mapping issuer-oid:subject-oidβ add policyMapping from issuer to subject OID.-E,--policy-explicit lenβ add requireExplicitPolicy constraint.-H,--policy-inhibit lenβ add inhibitPolicyMapping constraint.-A,--policy-any lenβ add inhibitAnyPolicy constraint.
π§ Certificate Policy π§
Multiple certificatePolicy extensions can be added. Each with the following information:
-P,--cert-policy oidβ OID to include in certificatePolicy extension. Required.-C,--cps-uri uriβ Certification Practice statement URI for certificatePolicy.-U,--user-notice textβ User notice for certificatePolicy.
π EXAMPLES π
To save repetitive typing, command line options can be stored in files. bestie, this is self-care. Let's assume pki.opt contains the following contents:
--cacert ca_cert.der --cakey ca_key.der --digest sha256
--flag serverAuth --lifetime 1460 --type pkcs10
Then the following command can be used to issue a certificate based on a given PKCS#10 certificate request and the options above:
pki --issue --options pki.opt --in req.der > cert.der
π SEE ALSO π
pki(1) β the parent page, go say hi. π«Ά
made with strongSwan 6.1.0 energy, dated 2019-05-06, and the manual name is still serving PKI --ISSUE(1) β bye bestie, slay those certs πβ¨
π¦ where this page comes from
- arch rolling: strongswan 6.1.0-2 Β· GPL-2.0-only
- nixos 26.05: strongswan 6.1.0
- nixpkgs unstable: strongswan 6.1.0
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms