Most efficient way to look whether a secret key is for X.509 or for OpenPGP
Rainer Perske
rainer.perske at uni-muenster.de
Thu Jan 3 02:04:38 CET 2019
Hello,
I use gpgsm and gpg2 concurrently. I can quickly and easily see whether
there are private keys in gnupghome/private-keys-v1.d/. But I cannot
easily see whether these keys belong to X.509 key pairs or to OpenPGP
key pairs.
For my application, I need to know:
a) What is the fastest way to detect whether I have a private X.509
key? I need a simple boolean answer: yes or no.
The response time of » gpgsm --list-secret-key « is .4 seconds, that
is far too long.
b) What is the fastest way to detect whether I have a private OpenPGP
key? I need a simple boolean answer: yes or no.
The response time of » gpg2 --list-secret-key « is .4 seconds, that
is far too long.
c) What is the fastest way to detect whether a private key in
gnupghome/private-keys-v1.d/ belongs to an X.509 key and/or to an
OpenPGP key? I need a simple answer: X.509-only, OpenPGP-only or
both.
The response time of » gpgsm --list-secret-key '&'${filename%.key} «
and » gpg2 --with-keygrip --list-secret-key | grep ${filename%.key}
« is 1 second, that is far too long
(My application needs these responses very quickly without any visible
delay. There is no time to wait for startup of gpg-agent, dirmngr or
any other daemon first. Perhaps there is already any indicator in the
.key file?)
Best regards
--
Rainer Perske
Abteilung Systembetrieb und Leiter der Zertifizierungsstelle (WWUCA)
Zentrum für Informationsverarbeitung (Universitätsrechenzentrum)
Westfälische Wilhelms-Universität
Zentrum für Informationsverarbeitung
Rainer Perske
Röntgenstraße 7-13
48149 Münster
Tel.: +49 251 83-31582
Fax.: +49 251 83-31555
E-Mail: rainer.perske at uni-muenster.de
WWW: https://www.uni-muenster.de/ZIV/Mitarbeiter/RainerPerske.shtml
Büro: Raum 006, Röntgenstraße 11
Lageplan: http://wwwuv2.uni-muenster.de/uniplan/?action=spot&gebnr=7474
Zertifizierungsstelle der Universität Münster (WWUCA):
Tel.: +49 251 83-31590
Fax.: +49 251 83-31555
E-Mail: ca at uni-muenster.de
WWW: https://www.uni-muenster.de/WWUCA/
Zentrum für Informationsverarbeitung (ZIV):
Tel.: +49 251 83-31600 (Mo-Fr 7:30-17:30 Uhr)
Fax.: +49 251 83-31555
E-Mail: ziv at uni-muenster.de
WWW: https://www.uni-muenster.de/ZIV/
-------------- next part --------------
A non-text attachment was scrubbed...
Name: smime.p7s
Type: application/pkcs7-signature
Size: 6807 bytes
Desc: S/MIME cryptographic signature
URL: <https://lists.gnupg.org/pipermail/gnupg-devel/attachments/20190103/552ee1f3/attachment.bin>
More information about the Gnupg-devel
mailing list