Skip to content

Commit

Permalink
Merge pull request #56 from frontegg/FR-17412-refresh-token-when-app-…
Browse files Browse the repository at this point in the history
…in-bg-and-phone-gets-locked

Changed `kSecAttrAccessible` with `kSecAttrAccessibleAfterFirstUnlock…
  • Loading branch information
alex-minaiev-frontegg authored Aug 12, 2024
2 parents 42e14cf + 1d09f65 commit b32ded3
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion Sources/FronteggSwift/services/CredentialManager.swift
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,8 @@ public class CredentialManager {
kSecClass: kSecClassGenericPassword,
kSecAttrService: serviceKey ?? "frontegg",
kSecAttrAccount: key,
kSecValueData: valueData
kSecValueData: valueData,
kSecAttrAccessible: kSecAttrAccessibleAfterFirstUnlock
] as [CFString : Any] as CFDictionary

let status = SecItemAdd(query, nil)
Expand All @@ -49,6 +50,7 @@ public class CredentialManager {
kSecClass: kSecClassGenericPassword,
kSecAttrService: serviceKey ?? "frontegg",
kSecAttrAccount: key,
kSecAttrAccessible: kSecAttrAccessibleAfterFirstUnlock
] as [CFString : Any] as CFDictionary

let newAttributes : CFDictionary = [
Expand Down

0 comments on commit b32ded3

Please sign in to comment.