Hi there,
I read a Microsoft paper explaining the basic concepts of encryption.
For example, I now understand the difference between asymmetric and
symmetric encryption and have successfully used the .NET crypto classes.
I'm now working on a project where I need to download a file from a bank
and process it. The bank's policy is encrypt the file using something called
a "PGP key." I need a way to decrypt it but I'm not sure where to start.
According to the admin at the bank, PGP is an asymmetric algorithm. I
interpreted this to mean that I would give the admin at the bank a public
key which he would use to encrypt the file and when I receive it, I'd
decrypt it with my private key. Correct?
So, I used the .NET classes to create the following public key and I
sent it to the admin at the bank:
<RSAKeyValue><Modulus>151Vw6Kq51bpblahblahblahWCkP mD345ncclzFrmeb9fjpE+B6VsIAqP3kahu00p33BmFpDpXOcgi uRC2En0HoGqyZB9ifvNlPhT7flZ1uVuC9JtywG3FmYRsqbpJuT 7VTIAHYExU6T/FyRuyIbhdUVwhue7ARaObsEWszE1IoM7+XcYYs=</Modulus><Exponent>AQAB</Exponent><P>+7OU6YErvfk84O/2bX5s2753xE+pdiyJl3j8gy4zMh4UKeKVhyxgSJJCvNTl9XVIy a6xnCWPkHVy8ylNqyLiHQ==</P><Q>20v7/nODe/jKcbsiYEwzGXp0ZyiG17JqzOBKrDFu6bwPiAEHzZln0CYfUn0E hJdCmetaq9WFXk27mbK3Z6aBxw==</Q><DP>RpoN6B26dlRGFlZZCkePI2he0esCfsppYdqnAejgpWs4 frM2/C6fZ1vXan5RbrOSUjg1S7ZhecToFHr+dUWYpQ==</DP><DQ>ayaHbF7YwfxgPo3nUBIrbamNstH0gPQmhxCYq+ZDgWV oWVXXkDgCp4vZBh8b1AVsf3SmCwv7bIaiwYi3YKfVBQ==</DQ><InverseQ>YjvieMYPEDdUHqSZRWAsFlEESd3NczFCrbBaS HzbsbOZeDrccvUfoOP2jeIhuMt0qQwMqXY/NJau9Ldwdx7xNw==</InverseQ><D>wEg6bM5LVSWoQgWpoldz5dQWfQjqQVc8WzKpDA HQ8ejsm0ug4ZwRcRRnKZs3o7OTsiAJCfjqT9ij1gKMoeLrXIM1 RDOcAYBxI0qwWdRrr3sbar7ntMYmy4tlTTf8/G+ypw+CJi1gz2umswcx4MHhNTUGTUHSmjEjDTFfh3sW64k=</D></RSAKeyValue>
He said that he had never seen a key like this before. He said that the
public key that I generate should look something like this:
---BEGIN PGP PUBLIC KEY BLOCK-----
Version: GnuPG v1.2.6 (GNU/Linux)
mQGiBD7ca+gRBADND4XM/Gb8HkdhPZ82AgVjKPUElAH4ohBnG0Fu/YHKmzqJWoB5
8uGnmXY5UYa2t1m//JluwJa/Dlb+1qlEXgZcDyTUFL/++le/a3yI2QQEo1XCO/VD
...and so on, blah blah
-----END PGP PUBLIC KEY BLOCK-----
Which begs the following questions:
How do I create a public PGP key using .NET?
How do I create a *private* PGP key using .NET?
How do I decrypt a PGP file using .NET?
Thanks,
Jules Winfield