Simple Swift wrapper for Keychain that works on iOS, watchOS, tvOS and macOS.
7.95k
stars
789
forks
source link
This function not working on live device but running perfectly on simulator, so please give answer of this function #602
Open
Rajshah555999 opened 5 months ago
func getPhrase() -> String? { var unencrypted: String? do { guard let encrypted = keychain["userSeedPhrase"] else { print("Error: Encrypted phrase not found in keychain") return nil } guard let encryptionKey = getPassword() else { print("Error: Encryption key not available") return nil } print("encrypted...(encrypted)") unencrypted = try encryption.decryptMessage (encryptedMessage: encrypted, encryptionKey: encryptionKey) } catch { print("Decryption Error: (error.localizedDescription)") } return unencrypted }