You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Sep 4, 2024. It is now read-only.
Describe the bug
A minority of users who swap devices, for whom apps using Magic SDK are automatically re-installed restore the keychain content, but do not enable access to it due to biometric signature differences.
This causes the DPop.swift line let signature = try! privateKey.signature(for: signingInputData) to crash irrecoverably.
In this case try retrieveKeyFromKeychain does not throw.
I raised a hopeful PR to patch the symptom but here's the Apple Forum reference that says they're aware of this issue but that you have you handle it yourself.
In the PR I prevent the crash, I'm not sure if this means you'll recreate the token later, or if the key would need to be explicitly removed as mentioned in the Apple Forum post above.
To Reproduce
Steps to reproduce the behavior:
Install an app with an active, cached auth credential from the Magic SDK
Buy a new device and use restore
Attempt to access a login flow that references Magic.getIdToken
See crash
Expected behavior
No crashes, a self-healing recoverable flow
Screenshots
If applicable, add screenshots to help explain your problem.
Environment
Package Version: 10.0.0
XCode Version: 15.2
Swift Version: 5.8
Simulator / Device OS: Device no OS specificity, os bug seems to have existed for several versions
Additional context
The text was updated successfully, but these errors were encountered:
tristan-warner-smith
changed the title
Crash for users setting up new devices with transferred apps
Crash for users setting up new devices (broken keychain)
Feb 7, 2024
Describe the bug
A minority of users who swap devices, for whom apps using Magic SDK are automatically re-installed restore the keychain content, but do not enable access to it due to biometric signature differences.
This causes the
DPop.swift
linelet signature = try! privateKey.signature(for: signingInputData)
to crash irrecoverably.In this case
try retrieveKeyFromKeychain
does notthrow
.I raised a hopeful PR to patch the symptom but here's the Apple Forum reference that says they're aware of this issue but that you have you handle it yourself.
In the PR I prevent the crash, I'm not sure if this means you'll recreate the token later, or if the key would need to be explicitly removed as mentioned in the Apple Forum post above.
To Reproduce
Steps to reproduce the behavior:
Magic.getIdToken
Expected behavior
No crashes, a self-healing recoverable flow
Screenshots


If applicable, add screenshots to help explain your problem.
Environment
Additional context
The text was updated successfully, but these errors were encountered: