Skip to content

Commit

Permalink
Workaround[auth]: don't match accessible attribute
Browse files Browse the repository at this point in the history
Trying to workaround weird issue with SEP-less palera1n environment
(iOS 16.7+ on A11)
  • Loading branch information
khanhduytran0 committed Jul 13, 2024
1 parent 563f25c commit dfe563d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion Natives/authenticator/MicrosoftAuthenticator.m
Original file line number Diff line number Diff line change
Expand Up @@ -244,7 +244,6 @@ + (NSDictionary *)keychainQueryForKey:(NSString *)profile extraInfo:(NSDictionar
(id)kSecClass: (id)kSecClassGenericPassword,
(id)kSecAttrService: @"AccountToken",
(id)kSecAttrAccount: profile,
(id)kSecAttrAccessible: (id)kSecAttrAccessibleWhenUnlockedThisDeviceOnly
}.mutableCopy;
if (extra) {
[dict addEntriesFromDictionary:extra];
Expand Down Expand Up @@ -281,6 +280,7 @@ - (BOOL)setAccessToken:(NSString *)accessToken refreshToken:(NSString *)refreshT
@"refreshToken": refreshToken,
} requiringSecureCoding:YES error:nil];
NSDictionary *dict = [MicrosoftAuthenticator keychainQueryForKey:self.authData[@"xuid"] extraInfo:@{
(id)kSecAttrAccessible: (id)kSecAttrAccessibleWhenUnlockedThisDeviceOnly,
(id)kSecValueData: data
}];
SecItemDelete((__bridge CFDictionaryRef)dict);
Expand Down

0 comments on commit dfe563d

Please sign in to comment.