Skip to content

fix(encryption): load wasm module on demand#18255

Merged
Antreesy merged 1 commit into
mainfrom
fix/noid/olm-load
Jun 25, 2026
Merged

fix(encryption): load wasm module on demand#18255
Antreesy merged 1 commit into
mainfrom
fix/noid/olm-load

Conversation

@Antreesy

@Antreesy Antreesy commented Jun 8, 2026

Copy link
Copy Markdown
Contributor

β˜‘οΈ Resolves

  • Encryption.isSupported() have a side effect of initializing Olm module
  • Should be pre-checked if needed by Encryption.isEnabled()
  • Already done in src/utils/webrtc/index.js, but not in src/utils/signaling.js
  • Migrated to async syntax

AI (if applicable)

  • The content of this PR was partly or fully generated using AI

πŸ–ŒοΈ UI Checklist

πŸ–ΌοΈ Screenshots / Screencasts

🏚️ Before 🏑 After
olm.wasm always loaded skipped

🚧 Tasks

  • @fancycode unless there is a reason to include features.push('encryption') from client side?

🏁 Checklist

  • 🌏 Tested with different browsers / clients:
    • Chromium (Chrome / Edge / Opera / Brave)
    • Firefox
    • Safari
    • Talk Desktop
    • Integrations with Files sidebar and other apps
    • Not risky to browser differences / client
  • πŸ–ŒοΈ Design was reviewed, approved or inspired by the design team
  • ⛑️ Tests are included or not possible
  • πŸ“— User documentation in https://github.com/nextcloud/documentation/tree/master/user_manual/talk has been updated or is not required

- Encryption.isSupported() have a side effect of initializing Olm module
- Should be pre-checked if needed by Encryption.isEnabled()
- Already done in src/utils/webrtc/index.js, but not in src/utils/signaling.js
- Migrated to async syntax

Signed-off-by: Maksim Sukharev <antreesy.web@gmail.com>
@Antreesy Antreesy added this to the β›… Next Major (35) milestone Jun 8, 2026
@Antreesy
Antreesy requested a review from fancycode June 8, 2026 10:29
@Antreesy Antreesy self-assigned this Jun 8, 2026

@fancycode fancycode left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

unless there is a reason to include features.push('encryption') from client side?

The SIP bridge checks that feature flag and only starts an e2ee session with a client if it is set, so it should not be removed.

Code looks good from a quick view, didn't test though.

Comment thread src/utils/signaling.js
@Antreesy
Antreesy requested review from DorraJaouad and ShGKme June 25, 2026 11:59
@Antreesy

Copy link
Copy Markdown
Contributor Author

/backport to stable34

@Antreesy
Antreesy merged commit aec8f35 into main Jun 25, 2026
53 checks passed
@Antreesy
Antreesy deleted the fix/noid/olm-load branch June 25, 2026 13:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants