Problem with public key encription

Werner Koch wk at
Fri Mar 4 10:14:51 CET 2005

On Thu, 03 Mar 2005 13:44:33 +0100, Madelman  said:

> (data
>   (flags raw)
>   (value #81ACBB98319D5EA67F63E28FC234790B#)
> )
> Result: Invalid object

Negative number.  You need to prefix it with 0x00.  This is only
required because you use raw data which is expected to be a proper
(non-negative) number.

Anyway, what you are trying to do is highly insecure.  You need to pad
the session key - use the pkcs#1 method.



More information about the Gcrypt-devel mailing list