5 ms·
Man-in-the-middle vulnerability on Gentoo sync and emerge
- zaroth 10y agoIs there an actual bug report somewhere or just a headline with some comments? I'm not saying you have to educate from first principles, but sure would be nice to include the use case, expected behavior, estimate on how widespread the effect, steps to reproduce,... This is basically a tweet.
- jsprogrammer 10y agoThe first comment linked to it[0]? [0] https://bugs.gentoo.org/show_bug.cgi?id=597800 https://bugs.gentoo.org/show_bug.cgi?id=597800
- deleted 10y ago[deleted]
- 0xmohit 10y agoAnother bug report [0] contains more details: This is dangerous as it is insecure default behavior. There may be an argument (poor) for keeping insecure default behavior. However, it is also doubly dangerous because it may imply to the user that the operation has been cryptographically verified when in fact it has not. Reproducible: Always Steps to Reproduce: 1. emerge-webrsync 2. "Fetching file portage-20161021.tar.xz.gpgsig ..." Actual Results: User things "cool, it's verified"... but it's not verified, and no warning is shown to this effect. Expected Results: All downloads are cryptographically verified or, failing that, a big (preferably red, flashing) SCARY WARNING is shown. Probably it should whinge immediately and require the addition of an --insecure command line flag. [0] https://bugs.gentoo.org/show_bug.cgi?id=597800 https://bugs.gentoo.org/show_bug.cgi?id=597800
- jlgaddis 10y agoThis bug (#597804) links to bug #597800 [0] titled "emerge-webrsync: Downloads .gpgsig by default, but doesn't verify it." That's where the details are (and probably where this submission should point). [0]: https://bugs.gentoo.org/show_bug.cgi?id=597800 https://bugs.gentoo.org/show_bug.cgi?id=597800
- hannob 10y agoPlease note that this is only related to the webrsync-method. While securing that would be good, it's not the default. So even if we had a secure emerge-webrsync-feature it'd still leave most users vulnerable.
- hannob 10y agoAs a long time gentoo dev I am happy that this gets more attention. Although this is an open secret and completely obvious. Gentoo's rsync-based system was always insecure. There have been multiple attempts to implement some kind of package signing, but it never made it to deployment. A workaround right now is to use git-based sync over https. You can sync from https://github.com/gentoo-mirror/gentoo https://github.com/gentoo-mirror/gentoo which is a copy of the portage tree with pregenerated metadata.
- contingencies 10y agoHehe. I discovered this after our last discussion on HN, so really it's your doing. If you have handbook edit rights fixing that would be a good temporary measure... I've made some suggestions for revision: https://wiki.gentoo.org/wiki/Handbook_Talk:AMD64/Installation/Stage#Portage_and_stage3_security_recommendations https://wiki.gentoo.org/wiki/Handbook_Talk:AMD64/Installatio...
- hannob 10y agoI don't think the github-solution will make it into the official handbook. People want to have everything on Gentoo-owned infrastructure, which I can understand.
- contingencies 10y agoI think the github thing is just a python GPG wrapper library that gkeys uses (and was written for that purpose), whereas the gkeys tool itself is already on Gentoo-owned infrastructure.
- cheiVia0 10y agoWho is it run by? It's not under https://github.com/gentoo https://github.com/gentoo and the gentoo-mirror org doesn't have any "public members" ... I'd be more concerned with trusting this, than my ISP or OSU OSL MITM-ing me. That aside, wouldn't it make sense to have the generated metadata in a separate repository? Sync the latest metadata, then check out the corresponding revision from the actual gentoo git repo.
- 0xmohit 10y agoLooks like this is in the process of getting fixed: https://bugs.gentoo.org/show_bug.cgi?id=597918 https://bugs.gentoo.org/show_bug.cgi?id=597918 The change is in the master: https://gitweb.gentoo.org/proj/portage.git/commit/?id=98c250cceaf380d6dbeacac90482a5d1956dcb80 https://gitweb.gentoo.org/proj/portage.git/commit/?id=98c250...
- TheDong 10y agoThose only refer to `emerge-webrsync`. That tool is typically used exactly once the first time a user installs gentoo. Every subsequent `emerge --sync` does not use that codepath, and so still needs a separate fix.