From 92a120c405b3283bc0af3287441527239d16e8b0 Mon Sep 17 00:00:00 2001 From: Julius Zint Date: Sat, 29 Aug 2020 13:27:10 +0200 Subject: [PATCH] Support for persistent TouchID unlock. While originally not intended, this changeset enables MacPass to unlock a database with TouchID even after the process is completly wiped. It does this by introducing multiple modes of operation. First: TouchId can be completly disabled. The TouchID checkbox is off and MacPass works like the TouchID feature had never been added. Second: The TouchID checkbox gets put into the mixed state. MacPass will now remember the database key in memory as long as the process remains alive and the database can be unlocked with TouchID until the applications terminates. Third: The TouchID checkbox is checked and MacPass will store the encrypted database key on a successfull unlock attempt in the standard userdefaults. TouchID unlock works now even after MacPass is completly terminated and restarted. --- MacPass/Base.lproj/PasswordInputView.xib | 4 +- MacPass/MPPasswordInputController.m | 105 +++++++++++++++-------- MacPass/MPSettingsHelper.h | 1 + MacPass/MPSettingsHelper.m | 1 + 4 files changed, 71 insertions(+), 40 deletions(-) diff --git a/MacPass/Base.lproj/PasswordInputView.xib b/MacPass/Base.lproj/PasswordInputView.xib index a8915f13..f455e2ef 100644 --- a/MacPass/Base.lproj/PasswordInputView.xib +++ b/MacPass/Base.lproj/PasswordInputView.xib @@ -152,14 +152,14 @@ DQ