diff options
author | Yves-Alexis Perez <corsac@corsac.net> | 2017-04-01 16:26:44 +0200 |
---|---|---|
committer | Yves-Alexis Perez <corsac@corsac.net> | 2017-04-01 16:26:44 +0200 |
commit | dc9380af81fbce8e1a9532b07bc671b9d346101b (patch) | |
tree | 219f7df0b01243ac1c41c7f679d1b4c6aef36b27 /src/pki/commands/gen.c | |
parent | 212c0ba74c0e453497b840f9cd131ec99f73754a (diff) | |
parent | 05ddd767992d68bb38c7f16ece142e8c2e9ae016 (diff) | |
download | vyos-strongswan-dc9380af81fbce8e1a9532b07bc671b9d346101b.tar.gz vyos-strongswan-dc9380af81fbce8e1a9532b07bc671b9d346101b.zip |
Merge tag 'upstream/5.5.2'
Upstream version 5.5.2
Diffstat (limited to 'src/pki/commands/gen.c')
-rw-r--r-- | src/pki/commands/gen.c | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/src/pki/commands/gen.c b/src/pki/commands/gen.c index 8b11854ad..6f14b5276 100644 --- a/src/pki/commands/gen.c +++ b/src/pki/commands/gen.c @@ -1,6 +1,6 @@ /* * Copyright (C) 2009 Martin Willi - * Copyright (C) 2014-2015 Andreas Steffen + * Copyright (C) 2014-2016 Andreas Steffen * HSR Hochschule fuer Technik Rapperswil * * This program is free software; you can redistribute it and/or modify it @@ -44,6 +44,10 @@ static int gen() { type = KEY_ECDSA; } + else if (streq(arg, "ed25519")) + { + type = KEY_ED25519; + } else if (streq(arg, "bliss")) { type = KEY_BLISS; @@ -101,6 +105,9 @@ static int gen() case KEY_ECDSA: size = 384; break; + case KEY_ED25519: + size = 256; + break; case KEY_BLISS: size = 1; break; @@ -159,7 +166,7 @@ static void __attribute__ ((constructor))reg() { command_register((command_t) { gen, 'g', "gen", "generate a new private key", - {" [--type rsa|ecdsa|bliss] [--size bits] [--safe-primes]", + {" [--type rsa|ecdsa|ed25519|bliss] [--size bits] [--safe-primes]", "[--shares n] [--threshold l] [--outform der|pem]"}, { {"help", 'h', 0, "show usage information"}, |