GnuPG - The GNU Privacy Guard
Recently got a chance to work on GnuPG to send and recieve secure data.worked with GnuPG with C#.NET to encrypt/decrypt data.
GnuPG is GNU's tool for secure communication and data storage.It can be used to encrypt data and to create digital signatures.It includes an advanced key management facility and is compliantwith the proposed OpenPGP Internet standard as described in RFC2440.
GnuPG works best on GNU/Linux or *BSD systems. Most other Unicesare also supported but are not as well tested as the Free Unices.See http://www.gnupg.org/download/supported_systems.html for alist of systems which are known to work.
Because GnuPG does not use use any patented algorithms it is notby default fully compatible with PGP 2.x, which uses the patentedIDEA algorithm. See http://www.gnupg.org/why-not-idea.html formore information on this subject, including what to do if you arelegally entitled to use IDEA.
The default public key algorithms are DSA and Elgamal, but RSA isalso supported. Symmetric algorithms available are AES (with 128,192, and 256 bit keys), 3DES, Blowfish, CAST5 and Twofish. Digestalgorithms available are MD5, RIPEMD/160, SHA-1, SHA-256, SHA-384,and SHA-512. Compression algorithms available are ZIP, ZLIB, andBZIP2 (with libbz2 installed).
GnuPG is GNU's tool for secure communication and data storage.It can be used to encrypt data and to create digital signatures.It includes an advanced key management facility and is compliantwith the proposed OpenPGP Internet standard as described in RFC2440.
GnuPG works best on GNU/Linux or *BSD systems. Most other Unicesare also supported but are not as well tested as the Free Unices.See http://www.gnupg.org/download/supported_systems.html for alist of systems which are known to work.
Because GnuPG does not use use any patented algorithms it is notby default fully compatible with PGP 2.x, which uses the patentedIDEA algorithm. See http://www.gnupg.org/why-not-idea.html formore information on this subject, including what to do if you arelegally entitled to use IDEA.
The default public key algorithms are DSA and Elgamal, but RSA isalso supported. Symmetric algorithms available are AES (with 128,192, and 256 bit keys), 3DES, Blowfish, CAST5 and Twofish. Digestalgorithms available are MD5, RIPEMD/160, SHA-1, SHA-256, SHA-384,and SHA-512. Compression algorithms available are ZIP, ZLIB, andBZIP2 (with libbz2 installed).
1 Comments:
At February 15, 2009 at 5:00 AM, syousuf said…
Hi,
I am working on decryting a pgp file using GnuPG.I want to do the same in a .NET C# Console Application.I want to send the passPhrase from the application itself,& don't want it to prompt.
I tried to passing the Passphrase from the application but its not working.
Finally,I want to decrypt the file,stream the dataout.My code is below.If you can kindly help me on this.
Here i have to manually put the passphrase & then i get the data stream in the Temp string variable.
——————-
using System;
using System.Collections.Generic;
using System.Text;
using System.Diagnostics;
using System.IO;
using System.Threading; // for Thread class
namespace ConsoleApplication3
{
class Program
{
static void Main(string[] args)
{
string passphrase = “$Trans@RtA09″;
Process myProcess = new Process();
StreamWriter sw;
StreamReader sr;
StreamReader err;
ProcessStartInfo myProcessStartInfo = new ProcessStartInfo(@”C:\gnupg\gpg.exe”);
myProcessStartInfo.Arguments = “–decrypt C:/Transfer/test.gpg”;
myProcessStartInfo.RedirectStandardError = true;
myProcessStartInfo.RedirectStandardInput = true;
myProcessStartInfo.RedirectStandardOutput = true;
myProcessStartInfo.UseShellExecute = false;
myProcess.StartInfo = myProcessStartInfo;
myProcess.Start();
sw = myProcess.StandardInput;
sr = myProcess.StandardOutput;
err = myProcess.StandardError;
sw.AutoFlush = true;
if (passphrase != null && passphrase != “”)//
{ //Here i am passing the passphrase,but it doesnot write in
sw.WriteLine(passphrase); //
} //
sw.Close();
String Temp = sr.ReadToEnd();
Temp += err.ReadToEnd();
}
}
------------------------------------------------------------------
Any help,will be highly appreciated.
Kind regards.
Post a Comment
<< Home