Problem with gcry_pk_decrypt (libgcrypt)

Werner Koch wk at gnupg.org
Wed Aug 3 16:15:25 CEST 2005


On Wed, 03 Aug 2005 14:33:57 +0200, Claudia Reuter said:

> I like to encrypt and decrypt large files e.g. pdf files. I wrote some
> code based on libgcrypt. I tested it with .txt files. Encryption seems
> to work, but gcry_pk_decrypt works only, if there's a single line in the
> txt file. If the txt file contains more than one line of text, the

Libgcrypt is a library of cryptographic building blocks.  At least a
medium level of cryptographic experience is required to make use of
it.

The usual way to encrypt large files is by using an hybrid approach.
It is simple impossible to use RSA to encrypt large blocks of data in
a secure and useful way.

You should better look into gpg or gpgme for your task.  


Salam-Shalom,

   Werner





More information about the Gnupg-users mailing list