r/programming • • Nov 24 '16

Let's Encrypt Everything

https://blog.codinghorror.com/lets-encrypt-everything/
3.5k Upvotes

508 comments sorted by

View all comments

311

u/VGPowerlord Nov 24 '16 edited Nov 24 '16

I feel like every time I read a Jeff Atwood article, I have to do fact checking. This one is no exception.

The performance penalty of HTTPS is gone, in fact, HTTPS arguably performs better than HTTP on modern devices.

Actually, this is false.

  1. HTTPS still has CPU and bandwidth performance penalties. They may not be as noticeable as in the past, but they are still present, particularly as encryption algorithms get more complex (there's a reason elliptical curve cryptography is recommended for HTTPS now).

  2. HTTP/2 was not finalized at the time the linked benchmark was posted.

  3. ...and because of that, this benchmark is out of date. Since it was published, HTTP/2 was revised to allow unencrypted connections. Which removes speed as a factor. And with that out of the way, HTTP will outperform HTTPS on the same protocol.

Using HTTPS means nobody can tamper with the content in your web browser.

Remember what I said before when I mentioned ECC Cryptography? It's not enough for a site to simply use HTTPS, they also have to use an encryption protocol that isn't yet broken. For example, all versions of SSL are currently broken. TLS supports some encryption protocols that are broken.

Browser manufacturers tend to update their browsers to reject broken protocols, but that doesn't help in businesses where they lock browsers at specific versions. See also: The IE6 problem, and its successor the IE8 problem. The flip side of the coin is application and web servers that stick with older protocols as well; I had to research this at my last job to bring out Oracle App Servers protocol list up to date to pass security scans.

182

u/pfg1 Nov 24 '16

There is no browser support for unencrypted HTTP/2, and no major browser vendor has plans to implement it. It might very well be impossible to deploy it without TLS for the same reasons browsers don't support HTTP 1.1 pipelining (proxies). The statement is quite accurate if you keep that in mind.

Similarly, since he's talking about modern devices, the CPU overhead for handshakes and encryption is negligible. I doubt you'd notice it on any desktop hardware released in the last 10 years, and as for mobile phones, it might be noticeable on low-end phones from a couple of years ago, but then again the handshakes and encryption are probably not what's going to be slowing down most sites on those phones. (I'm thinking JS performance, etc.)

46

u/damg Nov 24 '16

It still feels disingenuous to simply say HTTPS is faster than HTTP since it implies that encryption is what makes it faster, not that it's a prerequisite for a faster protocol.

17

u/Klathmon Nov 24 '16

Actually there are some tls 1.3 tests that would allow a zero RTT open, that's faster.

11

u/omnigrok Nov 24 '16

Yeah, but those are probably a bad idea. The 0-RTT opens for initial handshakes are breaking perfect forward secrecy (for resumptions, sure, go for it).

→ More replies (2)

12

u/jonbonazza Nov 24 '16

It should also be mentioned that HTTP/2 is not free. Both the server and client must support it for it to work. Telling people that don't know any better that HTTPS will perform better than HTTP when their servers likely don't support it is doing them a disservice.

→ More replies (3)

35

u/veeti Nov 24 '16

25

u/swishspitrinse Nov 24 '16

I was hoping to see a single-word answer as a heading, centred on a plain white page.

10

u/VanFailin Nov 24 '16

That is the convention for web sites of that form, though they're usually built for more cut-and-dry questions

→ More replies (1)

0

u/[deleted] Nov 24 '16

[deleted]

29

u/Badabinski Nov 24 '16

Counterpoint: HTTPS has a massive overhead when compared to HTTP because it makes caching impossible. Grabbing something over the LAN is at least an order of magnitude faster than grabbing something over the internet.

11

u/Kalium Nov 24 '16

If you really want to, you can rig a cacheing mitm-ing proxy for your local LAN.

8

u/Badabinski Nov 24 '16

That doesn't work for BYOD scenarios (events, retail stores, schools, anywhere with public wifi) and HSTS makes that impossible for a lot of sites.

8

u/Kalium Nov 24 '16

No, it doesn't work for BYOD scenarios, though if you're running a full proxy you can strip HSTS headers. This is a feature of HTTPS, rather than a bug. BYOD + LAN-local cache is indistinguishable from an attack.

What kind of scenario are you in where you have a strong reason to do this to your users while supporting BYOD?

11

u/Badabinski Nov 24 '16

A retailer has their entire catalog of videos on YouTube and want to make them available to people in the stores on their phones. Their pipe is incredibly slow and upgrading the pipe is prohibitively expensive. If they could cache YouTube on a local proxy cache it wouldn't be a problem. As it is, there's nothing this retailer can do.

→ More replies (7)
→ More replies (1)
→ More replies (3)
→ More replies (22)

18

u/dv_ Nov 24 '16

One thing I always wondered about HTTPS is how it is supposed to work with the internet of things. So I buy some small device with Internet connectivity. And this device supports only https, not http. How is the certificate registered? Who signs the certificate? And what if the certificate expires? Can you really expect Joe Average to handle self-signed certificates properly?

17

u/Klathmon Nov 24 '16

Automate it.

You probably don't know the ins and outs of how a secure bootloader works with code signing, but that doesn't stop your PC, Phone, and even game consoles from having them.

Something like LE with a button you can hit to setup a cert when you first setup the device and you are golden.

7

u/dv_ Nov 24 '16

Any articles on how to do that? I had the problem a while ago and decided to postpone HTTPS.

→ More replies (10)
→ More replies (2)

9

u/jmtd Nov 24 '16

I feel like every time I read a Jeff Atwood article, I have to do fact checking.

I usually have to double-check the date. I would have thought this was written 6 months ago if I hadn't checked.

14

u/[deleted] Nov 24 '16

arguably

Hey look, you proved him right!

32

u/VGPowerlord Nov 24 '16

As a company, we've donated a Discourse hosted support community

Also, don't get me started about Discourse, where members of a specific community of software developers, that were testing Discourse at Jeff Atwood's request, got mass banned from the Discourse Support forums for pointing out that something looked different in the mobile app versus the web browser on the same phone.

9

u/NeoKabuto Nov 24 '16

I didn't have time to read through all 58 pages there, but did he ever apologize or anything?

10

u/VGPowerlord Nov 24 '16

No.

In fact, he renamed his account on The Daily WTF to end and removed its avatar. I believe his profile said something about encouraging us to move to a different forum software. I think profile messages got lost at some point, though, because...

The Daily WTF no longers runs Discord, but migrated to new forum software. While it has its own bugs, its owners are willing to listen to our bug reports.

→ More replies (1)
→ More replies (2)
→ More replies (2)
→ More replies (29)