Opened 16 months ago

Last modified 2 weeks ago

#23888 new enhancement

Creating a Snowflake WebExtension addon

Reported by: oarel Owned by:
Priority: Medium Milestone:
Component: Obfuscation/Snowflake Version:
Severity: Normal Keywords: ux-team tor-pt
Cc: oarel@…, dcf, arlolra, mcs, antonela, gaba Actual Points:
Parent ID: Points:
Reviewer: Sponsor: Sponsor19

Description

The idea is to create a WebExtension that allows one to become a Snowflake bridge by just installing it. That way it only suffices to install an extension and forget about it, unlike the approach of keeping a tab always open with the snowflake JS code.

Since it's based on WebExtensions it can be easily deployed for other browsers in their addon store.

I did try to make one myself but I don't have the expertise and time to debug all the problems that resulted. One of the important take aways that I learned in that process was that automatically loading scripts from external sites is prohibited and will result in the addon not passing the review in the addon store, so the snowflake.js and modernizr.js should be embedded with the addon. However, this would require modifying snowflake.js since when it's loaded locally it throws some typeError and doesn't show that there's some connection to snowflake.bamsoftware.com in the browser console. For debugging, to verify that the addon works as intended one may load it from about:debug and check about:networking in the DNS and WebSockets part.

For the implementation these resources should be loaded in the background to ensure a permanent state with this in the manifest.json,

"background": {
                "page": "pages/Snowflake.html"
        },

Child Tickets

Attachments (5)

concept1.jpg (957.6 KB) - added by antonela 2 months ago.
concept2.jpg (783.0 KB) - added by antonela 2 months ago.
00.png (39.4 KB) - added by antonela 2 months ago.
01.png (40.1 KB) - added by antonela 2 months ago.
00.01.png (42.3 KB) - added by antonela 2 months ago.

Download all attachments as: .zip

Change History (16)

comment:1 Changed 16 months ago by arlolra

Cc: dcf arlolra added; dcf@… arlo@… removed

Thanks for your effort here. We've been discussing something like this in #20813

There's a fairly successful browser extension that's in the process (hopefully) of being converted to use snowflake in,
https://github.com/glamrock/cupcake/issues/24

comment:2 Changed 3 months ago by pili

Sponsor: Sponsor19

comment:3 Changed 2 months ago by antonela

Keywords: ux-team added

Added to ux-team roadmap

Changed 2 months ago by antonela

Attachment: concept1.jpg added

Changed 2 months ago by antonela

Attachment: concept2.jpg added

Changed 2 months ago by antonela

Attachment: 00.png added

Changed 2 months ago by antonela

Attachment: 01.png added

Changed 2 months ago by antonela

Attachment: 00.01.png added

comment:4 Changed 2 months ago by mcs

Cc: mcs added

comment:5 Changed 2 months ago by antonela

Hey, I hand-made some wireframes to explore some ideas around this web extension. With this web extension, users will have the option to enable/disable snowflake. You can see them here:

https://trac.torproject.org/projects/tor/raw-attachment/ticket/23888/concept1.jpg
https://trac.torproject.org/projects/tor/raw-attachment/ticket/23888/concept2.jpg

If this extension is a browserAction kind of extension, we should have a toolbar button with a popup. If that is the case, users will be able to enable webRTC globally.

In this scenario, the user will enable snowflake in global settings and users will not get informed when snowflake is transferring.

https://trac.torproject.org/projects/tor/raw-attachment/ticket/23888/00.png
https://trac.torproject.org/projects/tor/raw-attachment/ticket/23888/01.png

A second option could be having this extension working per site as a pageAction extension. Then, when the user visits a website which has webRTC available, the snowflake icon appears at the right side of the URL Bar and when it is transferring turn into violet. On first time use, if webRTC is not enabled, we should prompt the Control Center doorhanger to allow users to enable webRTC.

https://trac.torproject.org/projects/tor/raw-attachment/ticket/23888/00.01.png

Another option could be having both described above, running together. Here, the user can enable/disable snowflake globally on about:extensions. And, when webRTC is active in a site, then we can show the snowflake icon at the URL bar.

We could have Advanced Settings at the Extension Options page. There we can allow users to set some preferences about "how much of my bandwidth I want to give to snowflake" and another type of advanced network settings.



I think we can keep this idea raised in #27385 about to having the rotational motion on the snowflake when it is running.


I think that showing the number of peers connected to the bridge is rewarding for the user who is enabling the bridge. I also know that it is not possible now, but we can keep this in mind for later.


I think the snowflake icon should work better at small sizes. If you like to have that icon idea, I'll give it another round of work to synthesize the lines when it works small.

Next step for me is iterate over this mockups. Once we have defined how this extension will work, I'll create a prototype to see how the user flow works.

Last edited 2 months ago by antonela (previous) (diff)

comment:6 Changed 2 months ago by saint

As arlolra mentioned, after some discussion and delays, snowflake is to be included in Cupcake as a replacement for flashproxy. There are other roadmap items, but those are pushed back pending funding. Cupcake has ~4000 users on Chrome, and a few dozen on Firefox (which needs to be rewritten).

Currently, when flashproxy is active, the cupcake becomes a happy cupcake with eyes and a mustache. I did a lot of user testing with movement and soft/subtle gradient shifts, but unfortunately they all proved too distracting to end-users. The mustache is just enough of a change to be noticeable but not enough to steal focus from page content. So for snowflake, a color change would probably work better than a rotation.

comment:7 Changed 2 months ago by saint

Discussion ongoing at $dayjob about potentially placing a Snowflake snippet onto one of our most popular sites. So if you wanted to turn the changes above into a smaller form factor for the website badge, that would look pretty great. 👍

comment:8 Changed 2 months ago by gaba

Keywords: tor-pt added

comment:9 Changed 2 months ago by gaba

Cc: antonela gaba added

comment:10 in reply to:  6 Changed 2 months ago by antonela

Replying to saint:

As arlolra mentioned, after some discussion and delays, snowflake is to be included in Cupcake as a replacement for flashproxy. There are other roadmap items, but those are pushed back pending funding. Cupcake has ~4000 users on Chrome, and a few dozen on Firefox (which needs to be rewritten).

Wow that's awesome!

So for snowflake, a color change would probably work better than a rotation.

Yes, the main idea is having both: When it is disabled is grey, when it is enabled is violet and when it is enabled with clients, then we can add the rotation.

comment:11 Changed 2 weeks ago by cohosh

Here are some links to MassBrowser, a project by a University of Massachusetts research group on Browser-based proxies. I don't think it's a web extension, but some of the features available to proxies (being able to decide how much bandwidth to provide, what kinds of exit traffic to support, etc.) would be interesting to look into as features for the web extension.

Website (looks like their cert is bad): https://massbrowser.cs.umass.edu/

Technical report: https://web.cs.umass.edu/publication/docs/2018/UM-CS-2018-005.pdf

  • the most relevant section is probably Content Whitelisting

Code: https://github.com/SPIN-UMass/MassBrowser

Note: See TracTickets for help on using tickets.