Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

App crashes when performing Secure Backup #7871

Closed
nullnumber1 opened this issue Nov 13, 2024 · 6 comments
Closed

App crashes when performing Secure Backup #7871

nullnumber1 opened this issue Nov 13, 2024 · 6 comments
Labels
T-Defect Something isn't working: bugs, crashes, hangs and other reported problems

Comments

@nullnumber1
Copy link

nullnumber1 commented Nov 13, 2024

Steps to reproduce

  1. Navigate to Settings.
  2. Go to the Security section.
  3. Select Secure Backup and tap on "Set Up".
  4. Choose any of the options:
    • "Use a Security Key"
    • "Use a Security Phrase"

Outcome

  • First Attempt on "Set Up": When first pressing "Set Up", a pop-up appears with the message: Request failed: unauthorized (401).
  • Second Attempt on "Set Up": After tapping "Set Up" a second time, the menu with backup options opens as expected.

Issues with Each Backup Option

  1. "Use a Security Key"

    • Selecting "Use a Security Key" causes the app to crash immediately, without showing any options to share or copy the security key.
    • After the app crashes, the backup appears to be set up, but I wasn't able to backup the keys at the previous step.
  2. "Use a Security Phrase"

    • Selecting "Use a Security Phrase" allows me to input the security phrase. However, the app crashes immediately after proceeding.
    • After crashing and logging out and back into my account, if I attempt to restore from the backup using the security phrase I entered, the backup fails to restore

Your phone model

Iphone 12/Ipad Pro 12.9 M1

Operating system version

IOS17.6.1/iPadOS18.0.1

Application version

Element 1.11.19

Homeserver

Self hosted synapse inside docker (matrixdotorg/synapse) with federations disabled (tried on tags v1.118.0; v1.119.0)

Will you send logs?

Yes

Note

  • This issue was not present in the previous version of the app, where backup options worked as expected.
  • When talking about current and previous versions of the app, I talk about AppStore versions
@nullnumber1 nullnumber1 added the T-Defect Something isn't working: bugs, crashes, hangs and other reported problems label Nov 13, 2024
@matveytch
Copy link

Basically, have the same problem with such important feature, help please.

@NicolasBuquet
Copy link

@giomfo @pixlwave
The crash is due to a call in Matrix-ios-SDK to a method declared in the header file of Crypto/SecretStorage/MXSecretStorage but that is no more implemented.

The method is:

(MXHTTPOperation*)createKeyWithKeyId:(nullable NSString*)keyId
                               keyName:(nullable NSString*)keyName
                            passphrase:(nullable NSString*)passphrase
                               success:(void (^)(MXSecretStorageKeyCreationInfo *keyCreationInfo))success
                               failure:(void (^)(NSError *error))failure

Link to the header file declaration: https://github.com/matrix-org/matrix-ios-sdk/blob/34c66a0615173fb2d0252f8b9dc5d2650a58a847/MatrixSDK/Crypto/SecretStorage/MXSecretStorage.h#L92

@pixlwave
Copy link
Member

There's a fix for this at matrix-org/matrix-ios-sdk#1885. I think it's blocked on a review. Pinging @Velin92 / @BillCarsonFr.

@NicolasBuquet
Copy link

I tested the fix on my side and I can confirm it addresses the quirk.

@Velin92
Copy link
Member

Velin92 commented Nov 22, 2024

The fix has been merged and will be available in the next update of the SDK

@Velin92 Velin92 closed this as completed Nov 22, 2024
@NicolasBuquet
Copy link

Great. Thank you.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
T-Defect Something isn't working: bugs, crashes, hangs and other reported problems
Projects
None yet
Development

No branches or pull requests

5 participants