Update KeePassKit (Fixed Group order and Icon issue)

Enhanced database locking to actually encrypt the data although the file is not stored before (so changes might get lost)
Changed version handling a bit to make future export/save as possible
This commit is contained in:
michael starke
2013-09-03 00:44:55 +02:00
parent 0ae2946466
commit 2829e66877
10 changed files with 91 additions and 66 deletions

View File

@@ -60,19 +60,8 @@
id windowController = [[[self view] window] windowController];
MPDocument *document = [windowController document];
if(document) {
BOOL isOk = NO;
if(document.decrypted) {
// TODO: Fix unlocking to actually test
BOOL noPassword = !document.password && [[self.passwordTextField stringValue] length] == 0;
BOOL passwordOk = [document.password isEqualToString:[self.passwordTextField stringValue]];
BOOL noKey = document.key == [self.keyPathControl URL];
BOOL keyOk = [document.key isEqualTo:[self.keyPathControl URL]];
isOk = (noPassword || passwordOk) && (noKey || keyOk);
}
else {
isOk = [document unlockWithPassword:[self.passwordTextField stringValue] keyFileURL:[self.keyPathControl URL]];
}
if(!isOk) {
if(![document unlockWithPassword:[self.passwordTextField stringValue]
keyFileURL:[self.keyPathControl URL]]) {
[self _showError];
}
else {