1IPSEC_ECDSASIGKEY(8)          Executable programs         IPSEC_ECDSASIGKEY(8)
2
3
4

NAME

6       ipsec_ecdsasigkey - generate ECDSA signature key
7

SYNOPSIS

9       ipsec ecdsasigkey [--verbose] [--seeddev device] [--seed numbits]
10             [--nssdir nssdir] [--password nsspassword] [--hostname hostname]
11             [curvename]
12

DESCRIPTION

14       ecdsasigkey generates an ECDSA public/private key pair, suitable for
15       digital signatures, on a named curve specified with curvename.
16       Currently it only accepts secp256r1, secp384r1, and secp521r1.
17
18       The public exponent is forced to the value 3, which has important speed
19       advantages for signature checking. Beware that the resulting keys have
20       known weaknesses as encryption keys and should not be used for that
21       purpose.
22
23       The --verbose option makes ecdsasigkey give a running commentary on
24       standard error. By default, it works in silence until it is ready to
25       generate output.
26
27       The --seeddev option specifies a source for random bits used to seed
28       the crypto library's RNG. The default is /dev/random (see random(4)).
29       FreeS/WAN and Openswan without NSS support used this option to specify
30       the random source used to directly create keys. Libreswan only uses it
31       to seed the NSS crypto libraries RNG. Under Linux with hardware random
32       support, special devices might show up as /dev/*rng* devices. However,
33       these should never be accessed directly using this option, as hardware
34       failures could lead to extremely non-random values (streams of zeroes
35       have been observed in the wild)
36
37       The --seedbits option specifies how many seed bits are pulled from the
38       random device to seed the NSS PRNG. The default of 480bit comes from
39       FIPS requirements. Seed bits are rounded up to a multiple of 8.
40
41       The use of a different random device or a reduction of seedbits from
42       the default value is prevented when the system is running in FIPS mode.
43
44       The --nssdir option specifies the directory to use for the nss
45       database. This is the directory where the NSS certificate, key and
46       security modules databases reside. The default value is
47       /var/lib/ipsec/nss.
48
49       The --password option specifies the nss cryptographic module
50       authentication password if the NSS module has been configured to
51       require it. A password is required by hardware tokens and also by the
52       internal software token module when configured to run in FIPS mode. If
53       the argument is /etc/ipsec.d/nsspassword, the password comes from that
54       file; otherwise argument is the password.
55

EXAMPLES

57       ipsec ecdsasigkey --verbose 4096
58           generates a 4096-bit signature key and stores this key in the NSS
59           database. The public key can then be extracted and edited into the
60           ipsec.conf (see ipsec_showhostkey(8)).
61

FILES

63       /dev/random, /dev/urandom
64

SEE ALSO

66       random(4), rngd(8), ipsec_showhostkey(8), Applied Cryptography, 2nd.
67       ed., by Bruce Schneier, Wiley 1996, RFCs 2537, 2313, GNU MP, the GNU
68       multiple precision arithmetic library, edition 2.0.2, by Torbj Granlund
69

HISTORY

71       Originally written for the Linux FreeS/WAN project
72       <https://www.freeswan.org> by Henry Spencer. Updated for the Libreswan
73       Project by Paul Wouters.
74
75       The --round and --noopt options were obsoleted as these were only used
76       with the old non-library crypto code
77
78       The --random device is only used for seeding the crypto library, not
79       for direct random to generate keys
80

BUGS

82       ecdsasigkey's run time is difficult to predict, since /dev/random
83       output can be arbitrarily delayed if the system's entropy pool is low
84       on randomness, and the time taken by the search for primes is also
85       somewhat unpredictable. Specifically, embedded systems and most virtual
86       machines are low on entropy. In such a situation, consider generating
87       the ECDSA key on another machine, and copying ipsec.secrets and the
88       /var/lib/ipsec/nss directory tree to the embedded platform. Note that
89       NSS embeds the full path in the DB files, so the path on proxy machine
90       must be identical to the path on the destination machine.
91

AUTHOR

93       Paul Wouters
94           placeholder to suppress warning
95
96
97
98libreswan                         09/05/2023              IPSEC_ECDSASIGKEY(8)
Impressum