Discussion about out-of-band ruleset updates
(@Hainish, @cowlicks:)
There's a code branch https://github.com/EFForg/https-everywhere/tree/sign-rulesets that is intended to allow ruleset updates out-of-band from regular version updates. The idea is that HTTPS Everywhere will request ruleset updates from a central EFF server periodically with the effect that rulesets will update from time to time without the version year.month.day changing.
Privacy Badger does something similar for a whitelist it uses. Recently there were some problems with the updates which lead to a frustrating experience for me, see https://github.com/EFForg/privacybadger/issues/1466. After I understood what was happening, I argued against it, see for example https://github.com/EFForg/privacybadger/issues/1466#issuecomment-315792144 and the related discussion.
I think this is also a bad idea for HTTPS Everywhere and I'd like to understand why this change is being made. I would at least like to avoid the user experience of things cycling between breaking and working for no apparent reason that I had with Privacy Badger.
@cschanaj I use Chrome, not Tor Browser or Firefox, so you're wrong.
@koops76 I am not aware that it is possible to install HTTPSE on Chrome on an Android/ iOS devices. My apologies if I am wrong.
@cschanaj It's possible to install it on Firefox for Android (Fennec).
I suppose that HTTPS Everywhere will - if this is implemented - only download diffs and not the entire rulesets from start, is this correct? (If there's diffs then the download size can be very small)
AFAIK, defaults.rulesets is not really diff friendly in its raw format.
6.7M default.rulesets-2017.09.12.json
6.8M default.rulesets-2017.10.4.json
running
diff -u default.rulesets-2017.09.12.json default.rulesets-2017.10.4.json > hello.patch
14M hello.patch
Unless
cat default.rulesets-2017.09.12.json | python -m json.tool > pretty.rulesets-2017.09.12.json
cat default.rulesets-2017.10.4.json | python -m json.tool > pretty.rulesets-2017.10.4.json
diff -u pretty.rulesets-2017.09.12.json pretty.rulesets-2017.10.4.json > hello1.patch
174K hello1.patch
using diff has a huge potential but I am not really sure how this is going to be implement in the extension.
P.S. I am not sure whether or not it is possible to implement diff in javascript. So this is just for the reference on the diff obj size as compared to the actual ruleset.
One way to prepare a minimal update would be to check the git history for changes to ruleset files.
@I-have-50-open-PRs-to-HTTPS-EVERYWHERE:
I suppose that HTTPS Everywhere will - if this is implemented - only download diffs and not the entire rulesets from start, is this correct? (If there's diffs then the download size can be very small)
This is the eventual goal, but that's not how it's currently implemented. I agree this would be a big win, being that compared to the entirety of the rulesets, the diff is quite small. If the browser hasn't checked for updates recently (for instance if it hasn't been opened for a while) we could provide a mechanism to make available all previous diffs, performing an incremental migration.
The application of diffs can be difficult, though a cursory search reveals that there are potentially promising libraries for this purpose.
@cschanaj:
P.S. You can also track the user habit, possible time-zone/ occupations of a https-everywhere user by observing the regular pings to the EFF domains. Here I assumed that some users do quit the browsers when they finish everything and they have quality internet connections, such that disruption to the pings are mostly because of the user habits.
This is no different than the daily ping to addons.mozilla.org, though. I don't envision us pinging any more often than daily.
@jeremyn
I wish this feature had been discussed with the community before substantial work had been done.
If I had, then someone would most likely have wished I had a proof of concept was made available before asking for input. At any given point I'll be working on several features, I don't think it's reasonable to halt development and not work on a feature just because there may be feedback.
@Hainish Is this currently being implemented or is it still just an idea being debated, which may or may not be added.
@zero77 https://github.com/EFForg/https-everywhere/tree/sign-rulesets
@Hainish
At any given point I'll be working on several features, I don't think it's reasonable to halt development and not work on a feature just because there may be feedback.
That depends on how useful you expect community feedback to be, and how much ownership you think the community should have over features.
@Hainish, I've seen assumptions about this in other threads but we haven't heard any official word on this yet.
Do you plan on eventually allowing users to download rulesets from alternative sources or is this just a mechanism to simplify ruleset updates for clients which will remain EFF-only?
Because this could potentially be a good opportunity to revive projects like https://github.com/chris-barry/darkweb-everywhere.
@koops76 @HTTPSNowhere @cschanaj For the CDN issue I think using a p2p distribution approach using IPFS: https://ipfs.io/ may be a great solution to those problems. In addition IPFS can't be censored by blocking DNS https://ipfs.io/blog/24-uncensorable-wikipedia/ There's a JS implementation of IPFS: https://github.com/ipfs/js-ipfs But I don't think this should be given top priority currently.
@Bisaloo the plan is to publish the rulesets on a publicly accessible endpoint, with a signature. So yes, anyone will be able to download the rulesets and implement them in their own software. This includes downstream dependencies such as Brave or anyone else.
And check that they are valid by checking the signature, too.
@Bisaloo the plan is to publish the rulesets on a publicly accessible endpoint, with a signature. So yes, anyone will be able to download the rulesets and implement them in their own software. This includes downstream dependencies such as Brave or anyone else.
Sorry, I wasn't clear. My question is: will users be able to download rulesets from an alternative source?
In other words, is this a solution to https://github.com/EFForg/https-everywhere/issues/4380?
To expand on @Bisaloo 's question, this means that:
- HTTPS Everywhere would need to allow for alternate sources, and
- the providers of alternate sources would need to be able to sign their rulesets so HTTPS Everywhere allows them (either using a pre-installed key, or allowing users to add their own key), or
- HTTPS Everywhere would need to allow users to turn off the signature check for some sources
The apt/apt-key architecture used by Debian/Ubuntu is a potential model here.
@Bisaloo my thought is that at first, we would have the update channels hard-coded into the extension. The way it's currently implemented, update channels is an array, but it only contains one entry: the canonical rulesets. If Tor wanted to add a separate ruleset channel when they include HTTPS Everywhere within Tor Browser, they could do so by modifying update_channels.js at build time.
In time, I think it would be wonderful if we provide a UX so that users are able to add update channels and signing keys for those channels themselves. So ideally, someone could create a "Darkweb Everywhere" or similar ruleset and a signing key, and have users subscribe to it.
Related: https://trac.torproject.org/projects/tor/ticket/2161
@Hainish said,
At any given point I'll be working on several features, I don't think it's reasonable to halt development and not work on a feature just because there may be feedback.
@jeremyn said,
That depends on how useful you expect community feedback to be, and how much ownership you think the community should have over features.
This is a pretty important sub-conversation. I think there's a possible middle road here involving earlier heads-ups as well as clear signals to everyone involved about what phase a decision's in (e.g., "super open to fundamental change" versus "let's figure out how to implement this well").
Towards that goal, I've posted a tentative architectural/feature roadmap to the HTTPS Everywhere mailing list that I hope project maintainers will comment on; the items marked "Potential" in particular would probably benefit from replies on that list, or in relevant issues in this repo, on whether they'd be useful and implementation concerns/suggestions.