search for: convert_format

Displaying 3 results from an estimated 3 matches for "convert_format".

2012 Jul 28
1
[PATCH] ssh-keygen: support public key import/export using SubjectPublicKeyInfo
...efault conversion format is .Dq RFC4716 . .It Fl N Ar new_passphrase diff --git a/ssh-keygen.c b/ssh-keygen.c index 5fcd3a1..072c49a 100644 --- a/ssh-keygen.c +++ b/ssh-keygen.c @@ -137,7 +137,8 @@ int convert_from = 0; enum { FMT_RFC4716, FMT_PKCS8, - FMT_PEM + FMT_PEM, + FMT_SUBJECTINFO } convert_format = FMT_RFC4716; int print_public = 0; int print_generic = 0; @@ -330,6 +331,27 @@ do_convert_to_pem(Key *k) } static void +do_convert_to_subjectinfo(Key *k) +{ + switch (key_type_plain(k->type)) { + case KEY_RSA: + if (!PEM_write_RSA_PUBKEY(stdout, k->rsa)) + fatal("PEM_write_RSA...
2012 Sep 09
2
Patch for ssh-keygen to allow conversion of public key to openssh format
...ommon subdirectories: openssh-6.1p1/scard and openssh-6.1p1-lano/scard diff -u openssh-6.1p1/ssh-keygen.c openssh-6.1p1-lano/ssh-keygen.c --- openssh-6.1p1/ssh-keygen.c 2012-07-31 04:20:44.000000000 +0200 +++ openssh-6.1p1-lano/ssh-keygen.c 2012-09-07 09:26:01.000000000 +0200 @@ -141,6 +141,7 @@ } convert_format = FMT_RFC4716; int print_public = 0; int print_generic = 0; +int read_public_only = 0; char *key_type_name = NULL; @@ -240,6 +241,13 @@ char *pass; Key *prv; + if (read_public_only) { + Key *pub; + + pub = key_load_public(filename, NULL); +...
2020 Apr 25
2
[PATCH 1/3] Add private key protection information extraction to ssh-keygen
...dentity_file, &st) == -1) ??? ??? ?fatal("%s: %s: %s", __progname, identity_file, strerror(errno)); ??? ?if ((r = sshkey_load_public(identity_file, &k, NULL)) != 0) -?? ??? ?k = load_identity(identity_file, NULL); +?? ??? ?k = load_identity(identity_file, NULL, NULL); ??? ?switch (convert_format) { ??? ?case FMT_RFC4716: ??? ??? ?do_convert_to_ssh2(pw, k); @@ -806,19 +808,33 @@ do_print_public(struct passwd *pw) ??? ?struct stat st; ??? ?int r; ??? ?char *comment = NULL; +?? ?struct sshkey_vault *vault_info = NULL; ? ??? ?if (!have_identity) ??? ??? ?ask_filename(pw, "Enter file in wh...