How to import external RSA keys
Moritz Schulte
mo at g10code.com
Sat Jun 11 17:15:06 CEST 2005
On Wed, Jun 08, 2005 at 12:54:32PM +0200, Carolin Latze wrote:
> Has anybody an idea how to import these keys into a program written
> with the gcrypt.h?
I cannot give advice on the procedure of extracting the key from that
specific card, I can give general advice, though: as you probably
know, an RSA key consists of a few numbers (the so called `key
material'). What you have to do is:
* extract these numbers
* figure out the format of the numbers
* convert the numbers into a format supported by Libgcrypt
* make sure that the semantics regarding the numbers p, q, u match
those of Libgcrypt (u might need to be recomputed),
* convert the numbers to Libgcrypt MPI objects
* construct a complete key from the raw key material using either
the sexp/pk interface or the ac interface.
Hope this help a bit,
Moritz
--
Moritz Schulte
More information about the Gcrypt-devel
mailing list