- Bug 169353. Prompt user for Desktop Password when Master Password is not present.

This commit is contained in:
Jim Norman
2006-05-08 02:38:42 +00:00
parent f6a659b7eb
commit 837669576a
9 changed files with 11900 additions and 11371 deletions

View File

@@ -123,7 +123,6 @@ namespace sscs.cache
//return true;
}
if (sMasterPassword != null)
{
// verify MasterPassword
@@ -136,6 +135,29 @@ namespace sscs.cache
return false;
}
public bool IsDesktopPassword(string sDesktopPassword)
{
try
{
byte[] baPasscode = CASACrypto.GetMasterPasscodeUsingDesktopPasswd(sDesktopPassword, GetPasscodeByDesktopFilePath(), false);
if(CASACrypto.ValidatePasscode(baPasscode,GetValidationFilePath()))
{
return true;
}
// try old salt
baPasscode = CASACrypto.GetMasterPasscodeUsingDesktopPasswd(sDesktopPassword, GetPasscodeByDesktopFilePath(), true);
if(CASACrypto.ValidatePasscode(baPasscode,GetValidationFilePath()))
{
return true;
}
}
catch
{
}
return false;
}
internal bool StartPersistenceByDesktopPasswd(string desktopPasswd)
{