我想加密使用gpg,但即使我明确给出了路径,我得到这个错误..可以有人帮助我吗? 我正在使用Starksoft.Cryptography.OpenPGP。 我已经安装了gpg4win-light-2.1.0.exe来获取gpg.exe文件..gpg加密失败:文件打开错误
有没有我失踪的东西?
错误:未找到GPG可执行文件。 @C:\ Program Files \ GNU \ GnuPG \ gpg.exe \ gpg2.exe。
GnuPG gpg = new GnuPG();
gpg.BinaryPath = "@C:\\Program Files\\GNU\\GnuPG\\gpg.exe";
gpg.Recipient = "[email protected]";
FileStream sourceFile = new FileStream(sourcePath, FileMode.Open);
FileStream outputFile = new FileStream(Destinationpath, FileMode.Create);
gpg.Encrypt(sourceFile,outputFile);
sourceFile.Close();
outputFile.Close();
我甚至有一个openBlackboxPGP的许可证..我可以使用gpg加密吗?
如果我错过了一些东西,请帮助我! 在此先感谢!
(从评论更改为答案,请参阅下文。) – 2012-07-31 20:34:41