Java and GnuPG

Robert J. Hansen rjh at sixdemonbag.org
Fri May 18 13:15:28 CEST 2007


daneshwar.mishra at wipro.com wrote:
>  We are planning to use GPG tool in our application which is JAVA Based.
>  Could you please let me know that, how can i use GPG encryption and
> decryption using JAVA.

I would recommend against this if you're going to be running on Windows.

See, e.g.:

http://lists.gnupg.org/pipermail/gnupg-devel/2006-April/022832.html

... That bug is still unresolved.  It may still be lurking for you to
walk into, if you decide to write your own Java wrapper for GnuPG.

If you need OpenPGP from within Java, BouncyCastle is probably the
better way to go.  If you absolutely need GnuPG, then (a) don't host
your app on Windows and (b) just treat it like you would any other
Process.  E.g.:

http://java.sun.com/javase/6/docs/api/java/lang/Process.html





More information about the Gnupg-users mailing list