From adfbd68fc806c2c1fa79e0e878d2ff76a76bee8b Mon Sep 17 00:00:00 2001 From: Gluzskiy Alexandr Date: Tue, 31 Aug 2010 02:33:46 +0300 Subject: modified: gpg_wrapper.cpp modified: messages.cpp --- messages.cpp | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'messages.cpp') 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("\" "); -- cgit v1.2.3