This commit is contained in:
@@ -331,6 +331,7 @@ int CryptManager::CryptPK11EncryptString(char *clearData, int clearDataLen, char
|
||||
{
|
||||
// since we have specified password callback function , we won't come here...
|
||||
PrintMessage(MESG_ERROR, "\n CryptPK11EncryptString : PK11_Authenticate failed, possibly master password is wrong");
|
||||
(*PK11FreeSlot) (slot);
|
||||
return FPM_MASTERPASSWORD_WRONG;
|
||||
}
|
||||
|
||||
@@ -348,6 +349,7 @@ int CryptManager::CryptPK11EncryptString(char *clearData, int clearDataLen, char
|
||||
if (status != SECSuccess)
|
||||
{
|
||||
PrintMessage(MESG_ERROR, "\n CryptPK11EncryptString : PK11SDR_Encrypt failed ...");
|
||||
(*PK11FreeSlot) (slot);
|
||||
return FPM_FALSE;
|
||||
}
|
||||
|
||||
@@ -355,6 +357,7 @@ int CryptManager::CryptPK11EncryptString(char *clearData, int clearDataLen, char
|
||||
*cryptData = (char*)reply.data;
|
||||
*cryptDataLen = reply.len;
|
||||
|
||||
(*PK11FreeSlot) (slot);
|
||||
return FPM_TRUE;
|
||||
}
|
||||
|
||||
@@ -396,6 +399,7 @@ int CryptManager::CryptPK11DecryptString(char *decodeData, int decodeLen, char *
|
||||
{
|
||||
// since we have specified password callback function , we won't come here...
|
||||
PrintMessage(MESG_ERROR, "\n PK11_Authenticate failed, Probably master password is wrong");
|
||||
(*PK11FreeSlot) (slot);
|
||||
return FPM_MASTERPASSWORD_WRONG;
|
||||
}
|
||||
|
||||
@@ -414,6 +418,7 @@ int CryptManager::CryptPK11DecryptString(char *decodeData, int decodeLen, char *
|
||||
if (status != SECSuccess)
|
||||
{
|
||||
PrintMessage(MESG_ERROR, "\n PK11SDR_Decrypt failed ...");
|
||||
(*PK11FreeSlot) (slot);
|
||||
return FPM_FALSE;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user