Feature #16905

Speed up the checksum computation in the verification extension

Added by sajolida 2019-07-22 17:48:04 . Updated 2019-10-01 19:50:58 .

Status:
Confirmed
Priority:
Normal
Assignee:
Category:
Installation
Target version:
Start date:
Due date:
% Done:

0%

Feature Branch:
Type of work:
Code
Blueprint:

Starter:
1
Affected tool:
Verification Extension
Deliverable for:

Description

  • Back in 2015, DAVE used to rely on a native call (`nsICryptoHash`) which is not
    available anymore to WebExtensions. It was so fast that we never felt
    the need to measure how many seconds it took; probably less than 5.
  • The WebExtension relies on the Forge library and takes 45
    seconds on a Core i5 M520, around 10 times more.

Asking upstream a new API for checksum calculation sounds hard as it
would require lobbying both Mozilla and Chrome. An alternative could be
to rewrite the checksum calculation in
[WebAssembly](https://developer.mozilla.org/en-US/docs/WebAssembly).

This could be a good starter task for someone who knows JavaScript and WebAssembly as the README of the verification extension has detailed instructions for how to test it locally:

https://git.tails.boum.org/verification-extension/tree/README


Subtasks


Related issues

Related to Tails - Feature #14544: Spend software developer time on smallish UX improvements In Progress 2018-08-31

History

#1 Updated by sajolida 2019-07-22 18:22:34

  • related to Feature #14544: Spend software developer time on smallish UX improvements added

#2 Updated by intrigeri 2019-08-04 08:24:17

> An alternative could be to rewrite the checksum calculation in [WebAssembly](https://developer.mozilla.org/en-US/docs/WebAssembly).

Note that WebAssembly is currently disabled in Tor Browser, until it has been properly audited: https://trac.torproject.org/projects/tor/ticket/19417.

#3 Updated by Anonymous 2019-10-01 14:41:11

I would suggest to ask Enrico whenever he starts working on Feature #16128 and feels he has leftover time.

#4 Updated by sajolida 2019-10-01 19:50:58

Yes, it would be good to have some rough assessment on the feasibility of this while Enrico will be working on the iteration #1 of Feature #16128.

We’ll be 3 people working on this budget, so to think iteratively, I want to see how much iteration #1 of Feature #16128 cost to the team before deciding if we prioritize iteration #2 of 16128 or this ticket for the next iteration.