Update of /cvsroot/mahogany/M/src/modules/crypt
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv1513/src/modules/crypt
Modified Files:
PGPEngine.cpp
Log Message:
if PGP command is set to empty string, disable PGP signature verification
completely
Index: PGPEngine.cpp
===================================================================
RCS file: /cvsroot/mahogany/M/src/modules/crypt/PGPEngine.cpp,v
retrieving revision 1.36
retrieving revision 1.37
diff -b -u -2 -r1.36 -r1.37
--- PGPEngine.cpp 8 Sep 2004 22:13:43 -0000 1.36
+++ PGPEngine.cpp 11 Jul 2005 22:42:13 -0000 1.37
@@ -201,9 +201,24 @@
messageOut = messageIn;
+ // check if we have a PGP command: it can be set to nothing to disable pgp
+ // support
+ const String pgp = READ_APPCONFIG_TEXT(MP_PGP_COMMAND);
+ if ( pgp.empty() )
+ {
+ if ( log )
+ {
+ log->AddMessage(_("PGP command not configured, set its value in "
+ "the \"Helpers\" page of the preferences dialog "
+ "to enable PGP support"));
+ }
+
+ return OPERATION_CANCELED_BY_USER;
+ }
+
PGPProcess process;
String command = wxString::Format
(
_T("%s --status-fd=2 --command-fd 0 --output - -a %s"),
- READ_APPCONFIG_TEXT(MP_PGP_COMMAND).c_str(),
+ pgp.c_str(),
options.c_str()
);
@@ -214,9 +229,5 @@
#endif
- long pid = wxExecute
- (command,
- wxEXEC_ASYNC,
- &process
- );
+ long pid = wxExecute(command, wxEXEC_ASYNC, &process);
if ( !pid )
-------------------------------------------------------
This SF.Net email is sponsored by the 'Do More With Dual!' webinar happening
July 14 at 8am PDT/11am EDT. We invite you to explore the latest in dual
core and dual graphics technology at this free one hour event hosted by HP,
AMD, and NVIDIA. To register visit http://www.hp.com/go/dualwebinar
_______________________________________________
Mahogany-cvsupdates mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/mahogany-cvsupdates