summaryrefslogtreecommitdiff
path: root/messages.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'messages.cpp')
-rw-r--r--messages.cpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/messages.cpp b/messages.cpp
index 15972e4..a73205d 100644
--- a/messages.cpp
+++ b/messages.cpp
@@ -156,12 +156,14 @@ int RecvMsgSvc(WPARAM w, LPARAM l)
pass = UniGetContactSettingUtf(NULL, szGPGModuleName, "szKeyPassword", _T(""));
if(_tcslen(pass) > 0)
{
+ debuglog<<"info: found password in database, trying to decrypt message from "<<(TCHAR*)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, (WPARAM)hContact, GCDNF_TCHAR)<<"\n";
cmd += _T("--passphrase \"");
cmd += pass;
cmd += _T("\" ");
}
else if(password)
{
+ debuglog<<"info: found password in memory, trying to decrypt message from "<<(TCHAR*)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, (WPARAM)hContact, GCDNF_TCHAR)<<"\n";
cmd += _T("--passphrase \"");
cmd += password;
cmd += _T("\" ");
@@ -197,6 +199,7 @@ int RecvMsgSvc(WPARAM w, LPARAM l)
_terminate = false;
while(out.find("public key decryption failed: bad passphrase") != string::npos)
{
+ debuglog<<"info: failed to decrypt messaage from "<<(TCHAR*)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, (WPARAM)hContact, GCDNF_TCHAR)<<" password needed, trying to get one\n";
if(_terminate)
break;
{ //save inkey id
@@ -214,6 +217,7 @@ int RecvMsgSvc(WPARAM w, LPARAM l)
wstring cmd2 = cmd;
if(password)
{
+ debuglog<<"info: found password in memory, trying to decrypt message from "<<(TCHAR*)CallService(MS_CLIST_GETCONTACTDISPLAYNAME, (WPARAM)hContact, GCDNF_TCHAR)<<"\n";
wstring tmp = _T("--passphrase \"");
tmp += password;
tmp += _T("\" ");