diff options
author | Tobias Brunner <tobias@strongswan.org> | 2016-08-31 17:57:12 +0200 |
---|---|---|
committer | Tobias Brunner <tobias@strongswan.org> | 2016-10-05 11:32:52 +0200 |
commit | 05ccde0a8bd9d669fa186aa4d4a3d37d2a8155c1 (patch) | |
tree | da1e72e8d744aaefe34d03b26b3f5859c3686f51 /src/pki/commands/issue.c | |
parent | 4a6f97d00bb5ed022ec8e06360e4cdc53ea536f6 (diff) | |
download | strongswan-05ccde0a8bd9d669fa186aa4d4a3d37d2a8155c1.tar.bz2 strongswan-05ccde0a8bd9d669fa186aa4d4a3d37d2a8155c1.tar.xz |
pki: Add generic 'priv' key type that loads any type of private key
Diffstat (limited to 'src/pki/commands/issue.c')
-rw-r--r-- | src/pki/commands/issue.c | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/src/pki/commands/issue.c b/src/pki/commands/issue.c index fdc43d705..b15f90199 100644 --- a/src/pki/commands/issue.c +++ b/src/pki/commands/issue.c @@ -117,6 +117,11 @@ static int issue() type = CRED_PRIVATE_KEY; subtype = KEY_BLISS; } + else if (streq(arg, "priv")) + { + type = CRED_PRIVATE_KEY; + subtype = KEY_ANY; + } else if (!streq(arg, "pub")) { error = "invalid input type"; @@ -580,7 +585,7 @@ static void __attribute__ ((constructor))reg() command_register((command_t) { issue, 'i', "issue", "issue a certificate using a CA certificate and key", - {"[--in file] [--type pub|pkcs10|rsa|ecdsa|bliss] --cakey file|--cakeyid hex", + {"[--in file] [--type pub|pkcs10|priv|rsa|ecdsa|bliss] --cakey file|--cakeyid hex", " --cacert file [--dn subject-dn] [--san subjectAltName]+", "[--lifetime days] [--serial hex] [--ca] [--pathlen len]", "[--flag serverAuth|clientAuth|crlSign|ocspSigning|msSmartcardLogon]+", |