diff --git a/MacPass.xcodeproj/project.pbxproj b/MacPass.xcodeproj/project.pbxproj index 4eda3212..57e7b9df 100644 --- a/MacPass.xcodeproj/project.pbxproj +++ b/MacPass.xcodeproj/project.pbxproj @@ -232,6 +232,7 @@ 4CAD748C15B889B700104512 /* Security.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 4CAD748B15B889B700104512 /* Security.framework */; }; 4CAD748E15B88AC100104512 /* libz.dylib in Frameworks */ = {isa = PBXBuildFile; fileRef = 4CAD748D15B88AC100104512 /* libz.dylib */; }; 4CAD8AA622CF397B0090B2DD /* MPAutotypeDoctorReportViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 4CAD8AA422CF397B0090B2DD /* MPAutotypeDoctorReportViewController.m */; }; + 4CB11241256EB77900204D1B /* KPKEntry+OTP.m in Sources */ = {isa = PBXBuildFile; fileRef = 4CB11240256EB77900204D1B /* KPKEntry+OTP.m */; }; 4CB33F861EAF54A000C9341E /* KPKNode+MPIsHistory.m in Sources */ = {isa = PBXBuildFile; fileRef = 4CB33F851EAF54A000C9341E /* KPKNode+MPIsHistory.m */; }; 4CB9339916D3A0DD00A13B5D /* Credits.rtf in Resources */ = {isa = PBXBuildFile; fileRef = 4CB9339716D3A0DD00A13B5D /* Credits.rtf */; }; 4CBA2ABA17074C07006D8139 /* MPSettingsHelper.m in Sources */ = {isa = PBXBuildFile; fileRef = 4CBA2AB917074C07006D8139 /* MPSettingsHelper.m */; }; @@ -782,6 +783,8 @@ 4CAD748D15B88AC100104512 /* libz.dylib */ = {isa = PBXFileReference; lastKnownFileType = "compiled.mach-o.dylib"; name = libz.dylib; path = usr/lib/libz.dylib; sourceTree = SDKROOT; }; 4CAD8AA322CF397B0090B2DD /* MPAutotypeDoctorReportViewController.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = MPAutotypeDoctorReportViewController.h; sourceTree = ""; }; 4CAD8AA422CF397B0090B2DD /* MPAutotypeDoctorReportViewController.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = MPAutotypeDoctorReportViewController.m; sourceTree = ""; }; + 4CB1123F256EB77900204D1B /* KPKEntry+OTP.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = "KPKEntry+OTP.h"; sourceTree = ""; }; + 4CB11240256EB77900204D1B /* KPKEntry+OTP.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = "KPKEntry+OTP.m"; sourceTree = ""; }; 4CB33F841EAF54A000C9341E /* KPKNode+MPIsHistory.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "KPKNode+MPIsHistory.h"; sourceTree = ""; }; 4CB33F851EAF54A000C9341E /* KPKNode+MPIsHistory.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = "KPKNode+MPIsHistory.m"; sourceTree = ""; }; 4CB63A6018986530002DEC4C /* MPFlagsHelper.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = MPFlagsHelper.h; sourceTree = ""; }; @@ -1192,6 +1195,8 @@ 4C0949581FD6B89B004F2971 /* NSUserNotification+MPAdditions.m */, 4C6BF0742559BD4800E5812A /* KPKBinary+MacPassAddtions.h */, 4C6BF0752559BD4800E5812A /* KPKBinary+MacPassAddtions.m */, + 4CB1123F256EB77900204D1B /* KPKEntry+OTP.h */, + 4CB11240256EB77900204D1B /* KPKEntry+OTP.m */, ); name = Categories; sourceTree = ""; @@ -1542,6 +1547,7 @@ 4C77E36C15B84A240093A587 /* MacPass */ = { isa = PBXGroup; children = ( + 4CB1123E256EB74E00204D1B /* OTP */, 4CF9ECAE1BFDEC5700C58E99 /* Plugin */, 4C217D8E17A32BCF00609FAA /* Common */, 4C104129178CDD26001B5239 /* Categories */, @@ -1696,6 +1702,13 @@ name = Protocolls; sourceTree = ""; }; + 4CB1123E256EB74E00204D1B /* OTP */ = { + isa = PBXGroup; + children = ( + ); + name = OTP; + sourceTree = ""; + }; 4CCFA12C1BF0CC7A0078E0A1 /* Databases */ = { isa = PBXGroup; children = ( @@ -2172,6 +2185,7 @@ 4CE298EB1795FC2A00DF7BDB /* MPEntryContextMenuDelegate.m in Sources */, 4CCCE8011D75CA48006AA951 /* MPArrayController.m in Sources */, 4CC0D2CE17974A47000B4BDA /* MPCustomFieldTableViewDelegate.m in Sources */, + 4CB11241256EB77900204D1B /* KPKEntry+OTP.m in Sources */, 4CC0D2D117974A5A000B4BDA /* MPAttachmentTableViewDelegate.m in Sources */, 4C26C33F18D8C92100CF1A1C /* MPTemporaryFileStorage.m in Sources */, 4C663D411D6D91A900CB6237 /* MPNumberFormatter.m in Sources */, diff --git a/MacPass/KPKEntry+OTP.h b/MacPass/KPKEntry+OTP.h new file mode 100644 index 00000000..c465ed8c --- /dev/null +++ b/MacPass/KPKEntry+OTP.h @@ -0,0 +1,19 @@ +// +// KPKEntry+OTP.h +// MacPass +// +// Created by Michael Starke on 25.11.20. +// Copyright © 2020 HicknHack Software GmbH. All rights reserved. +// + +#import + +NS_ASSUME_NONNULL_BEGIN + +@interface KPKEntry (OTP) + +@property (readonly, assign, nonatomic) BOOL hasTOTP; + +@end + +NS_ASSUME_NONNULL_END diff --git a/MacPass/KPKEntry+OTP.m b/MacPass/KPKEntry+OTP.m new file mode 100644 index 00000000..133d344e --- /dev/null +++ b/MacPass/KPKEntry+OTP.m @@ -0,0 +1,21 @@ +// +// KPKEntry+OTP.m +// MacPass +// +// Created by Michael Starke on 25.11.20. +// Copyright © 2020 HicknHack Software GmbH. All rights reserved. +// + +#import "KPKEntry+OTP.h" + +@implementation KPKEntry (OTP) + ++ (NSSet *)keyPathsForValuesAffectingHasTOTP { + return [NSSet setWithObject:NSStringFromSelector(@selector(attributes))]; +} + +- (BOOL)hasTOTP { + return NO; +} + +@end