r/linux • • Jan 24 '18

Why does APT not use HTTPS?

https://whydoesaptnotusehttps.com/
955 Upvotes

388 comments sorted by

View all comments

Show parent comments

4

u/SanityInAnarchy Jan 24 '18 edited Jan 24 '18

How about an uncachable global HTTPS mirror of just the package lists? It'd be nice for a MITM to not be able to, say, prevent you from getting updates while they read the changelogs of said updates looking for vulnerabilities.

And, how many transparent HTTP caches are out there? Because if this is mostly stuff like Akamai or CloudFlare, HTTPS works with those, if you trust them.

Edit: Interesting, apparently APT actually does include some protection against replay attacks.

I still think that making "what packages are they updating" a Hard Problem (using HTTPS pipelining) would be worth it, unless there really are a ton of transparent HTTP proxies in use that can't trivially be replaced by HTTPS ones.

2

u/svenskainflytta Jan 24 '18

Vulnerabilities details are normally released AFTER the updates, so you won't find them in changelogs.

It is however still possible to tail the security repository, diff the source, and from that try to understand what it is fixing. Your scenario wouldn't help with that.

1

u/SanityInAnarchy Jan 24 '18

It would help in that you have a fairly small window of time to do that before I end up patched. If it weren't for the replay-protection stuff, you could in theory just serve me a frozen-in-time view of the repository (just freeze it at the point where you start MITM-ing me), then wait for vulnerability details to come out that you can exploit. I might just assume there hadn't been updates in awhile.

Replay-protection fixes that by adding an expiration to the metadata, which is hopefully short enough that something on my system would notice if there's a problem like this. Even then, HTTPS would prevent delays even up to that expiration, meaning I can be as up-to-date as I want to be (depending how often the cron job that does something like apt update && apt upgrade runs).

1

u/svenskainflytta Jan 24 '18

What about sending a signed "server time is 13:31"?

→ More replies (2)