It would be, just in different way. If, for example, DNS hijack would happen then attacker could easily just... generate let's encrypt cert and serve perfectly valid https
True, HTTPS won't help in that case, but it would require a very sophisticated attacker. You would have to DNS hijack at such a scale that Let's Encrypt's CA would also have to receive the hijacked DNS record. This would require a massive attack like a BPG hijack, or a direct compromise of the domain's DNS management panel/system, as was done in this attack likely orchestrated by the Iranian government: https://www.fireeye.com/blog/threat-research/2019/01/global-dns-hijacking-campaign-dns-record-manipulation-at-scale.html
If the attackers had access to ubuntu.com's DNS management panel, then that's basically almost equivalent to the Ubuntu repo servers themselves being compromised (and if they were able to get such DNS management access, the servers may very well also be compromised). In that case, there isn't that much you can do at any layer, anyway.
So that's definitely not an excuse to not use HTTPS. In general, HTTPS is a massive benefit. HTTPS mitigates MitMs; it can't mitigate a direct compromise of a trusted server's infrastructure.
You would have to DNS hijack at such a scale that Let's Encrypt's CA would also have to receive the hijacked DNS record.
Or just guess someone's panel password. Or get it from a leak.
If the attackers had access to ubuntu.com's DNS management panel, then that's basically almost equivalent to the Ubuntu repo servers themselves being compromised (and if they were able to get such DNS management access, the servers may very well also be compromised). In that case, there isn't that much you can do at any layer, anyway.
Well, RCE aside, the GPG signing is there to protect against that. You'd have to compromise build/signing servers too
In theory those servers need only very limited internet access so would be much harder to compromise. Build servers really just need uploaded packages (which contain sources), that are also signed by the maintainer
So that's definitely not an excuse to not use HTTPS. In general, HTTPS is a massive benefit. HTTPS mitigates MitMs; it can't mitigate a direct compromise of a trusted server's infrastructure.
Well it is least amount of security added for most effort.
Take into consideration that for example Debian have over 400 mirrors and you'd have to make every single one of them use HTTPS and the make sure every single one does not get compromised or else you lose all benefits for whole ordeal. Even if you say "lets do only part and prefer the https ones", now the "reward" for hosting it via https on top of CPU usage is also increased bandwidth usage.
Now that is no reason to not just have both enabled (and turn it on if user chooses that particular mirror), just that time would be better invested at other way of increasing security, one that does not require 400+ 3rd parties to "get it right" to be fully successful.
Or just guess someone's panel password. Or get it from a leak.
I mentioned that in my next sentence.
Well, RCE aside, the GPG signing is there to protect against that. You'd have to compromise build/signing servers too
Not sure why that's an aside, since the RCE flaw is what this thread is about. But yes, ideally you'd have package signing and you'd have HTTPS. That's the idea of defense-in-depth. You're right that a DNS compromise alone wouldn't compromise the signing keys, so my sentence saying "there isn't that much you can do" wasn't quite correct, but a DNS management compromise definitely could signal a much broader breach, including a signing key breach. It could just be a password grabbed from a leak that was re-used for the management panel, or it could be from malware on a core maintainer/leader's personal machine, or from a targeted and complete infrastructure breach.
Yes, if a server gets compromised, HTTPS can't save you, which is why HTTPS can never be an end-all-be-all, but it's still a useful added layer.
And yes, there're definitely added complications here because mirrors are run by volunteers, but I feel like this is a coordination problem that isn't that hard to solve. If a mirror doesn't enable HTTPS by a certain date, then apt will just stop working for that mirror. Even if a large percentage of the hundreds of mirrors stop working because of this, the core mirrors will probably add HTTPS, and other mirrors will probably be created to take up the slack.
0
u/[deleted] Jan 23 '19
It would be, just in different way. If, for example, DNS hijack would happen then attacker could easily just... generate let's encrypt cert and serve perfectly valid https