1PKI --PUB(1) strongSwan PKI --PUB(1)
2
3
4
6 pki --pub - Extract a public key from a private key or certificate
7
9 pki --pub [--in file|--keyid hex] [--type type] [--outform encoding]
10 [--debug level]
11
12 pki --pub --options file
13
14 pki --pub -h | --help
15
17 This sub-command of pki(1) extracts public keys from a private keys and
18 certificates.
19
21 -h, --help
22 Print usage information with a summary of the available options.
23
24 -v, --debug level
25 Set debug level, default: 1.
26
27 -+, --options file
28 Read command line options from file.
29
30 -i, --in file
31 Input file. If not given the input is read from STDIN.
32
33 -t, --type type
34 Type of input. One of rsa (RSA private key), ecdsa (ECDSA pri‐
35 vate key), pub (public key), pkcs10 (PKCS#10 certificate
36 request), or x509 (X.509 certificate), defaults to rsa.
37
38 -f, --outform encoding
39 Encoding of the extracted public key. One of der (ASN.1 DER),
40 pem (Base64 PEM), dnskey (RFC 3110 DNS key), or sshkey (RFC 4253
41 SSH key), defaults to der.
42
44 Extract the public key from an RSA private key:
45
46 pki --pub --in key.der > pub.der
47
48 Extract the public key from an X.509 certificate:
49
50 pki --pub --in cert.der --type x509 > pub.der
51
53 pki(1)
54
55
56
575.2.0 2013-07-31 PKI --PUB(1)