5 ms·
Shouldn't encryption be part of TCP/IP, rather than have every application including web browsers reinvent the wheel?
by amelius 10y ago
Shouldn't encryption be part of TCP/IP, rather than have every application including web browsers reinvent the wheel?
- niftich 10y agoIf Google has its way, encryption is a part of their TCP-replacement, QUIC [1]. Google products already use QUIC in the wild; Firefox is adding it soon [2]; curl put out a request for a QUIC library [3]. [1] https://tools.ietf.org/html/draft-hamilton-early-deployment-quic-00 https://tools.ietf.org/html/draft-hamilton-early-deployment-... [2] https://bugzilla.mozilla.org/show_bug.cgi?id=1158011 https://bugzilla.mozilla.org/show_bug.cgi?id=1158011 [3] https://daniel.haxx.se/blog/2016/07/20/curl-wants-to-quic/ https://daniel.haxx.se/blog/2016/07/20/curl-wants-to-quic/
- tptacek 10y agoQUIC is sort of a counterexample, but it's also an example of a vertically-integrated application protocol that takes responsibility for transport as well.
- geofft 10y agoNo, it should not. TCP/IP doesn't have a concept of names. I want to know that I am sending my HN password / login cookies to news.ycombinator.com. I don't have any idea whether I should send my HN password to 104.20.43.44:80 or not. You could imagine a more complex architecture involving DNSSEC and results from getaddrinfo(), but that seems to break the end-to-end principle (it is the browser that cares whether I am actually talking to news.ycombinator.com or not) and also reinvent the wheel. We have an HTTPS ecosystem that works pretty well. We do not have a secure DNS system that works pretty well, let alone a secure TCP/IP one.
- tptacek 10y agoNo, it should not. Security involves policy decisions; for instance, "how should I respond when confronted with an expired certificate with a valid signature", or, "how should I handle a certificate when I can't verify whether it's been revoked", or "how should I handle a valid certificate for a pinned domain". Sometimes the answer is "just go ahead but lose the green bar". Sometimes the answer is "pop a click-through warning". (We click through these warnings, but they bounce significant numbers of end users). Sometimes the answer is "scream bloody murder to the browser vendor". What does it even mean to trust a signature? Do we trust things that come from hierarchical PKIs? Would we rather rely mostly on key continuity, like SSH does? Do we want to build something like Moxie Marlinspike's Convergence, long term, so we can choose which authorities we trust? All of these concerns that I listed could be handled in an encryption capability that resided directly in the transport layer. But we'd inevitably come up with concerns that were difficult to handle there --- for instance, if it's part of TCP/IP, the code is mostly kernel resident, and maybe it's super hard (even harder than it is now) to get Curve25519 deployed. This isn't so much insight on my part as it is the stated conclusion, about security in particular, of Saltzer, Reed, and Clark's "End To End Argument In Systems Design", which is one of the foundational documents of the Internet: http://web.mit.edu/Saltzer/www/publications/endtoend/endtoend.txt http://web.mit.edu/Saltzer/www/publications/endtoend/endtoen... Push things as far towards the application layer as they'll go, and keep the lower-layer protocols dumb, so they don't get in the way. Here's a more reasonable approach that probably addresses the concerns you have about there being multiple app-layer crypto protocols: http://noiseprotocol.org/ http://noiseprotocol.org/
- fulafel 10y agoIPSec admitted and reacted to this too late, but they were going to handle it by giving the policy choices to the application through socket options. See IPSec Channel Bindings RFC (RFC5660) and unfinished specs at http://www.potaroo.net/ietf/html/ids-wg-btns.html http://www.potaroo.net/ietf/html/ids-wg-btns.html for where this work was heading.
- fulafel 10y agoIt is (IPSec) but it's not popular due to various technical, historical and political reasons. One of the selling points of IPv6 used to be that IPSec support is mandatory in IPv6. Nowadays middleboxes violating basic TCP/IP guarantees[1] are so accepted and entrenched that all new protocol work necessarily uses UDP encapsulation. (See eg WebRTC data channels, that's SCTP over DTLS over UDP...) [1] Many are calling NAT boxes "routers" even though the most central specified requirement of an IP router is to pass IP datagrams through with addressing information unaltered!
- tptacek 10y agoA lot of the complexity in IPSec shakes out of the fact that it's difficult to make a secure transport that's right for every protocol, which is what you have to do if you're trying to bake encryption into IP.
- Panino 10y agoNo. Just imagine the encryption we'd have in IPv4 -- none, and for multiple reasons: too expensive, public crypto was considered a "munition" when IPv4 was developed, etc. How about IPv6? We'd most likely have 40-bit export ciphers, if anything, but crypto was still considered a "munition" by the US govt when IPv6 work began in the 1990s. Perhaps IPv6 would have taken longer due to that fight, and later adopted 40-bit export if we were "lucky." IPv6 carries a measurable percentage of Internet traffic now, but when it was developed, in the 1990s, public crypto sucked. And so that's what would be baked into IPv6 now, for all time. I totally get the appeal of having all traffic automatically encrypted, it's just that A) IETF would screw it up somehow and B) it would take too long to deploy through "official" channels. It would turn into an unwanted Christmas present, 20 years too late. The alternative offers much stronger crypto and a much faster deployment timetable: let the public build encrypted protocols based on UDP. If they work, maybe people will use them. There's actually been some success here, like with QUIC, Noise, etc. I think we need to get beyond the idea of waiting for standards bodies to give us state-of-the-art. They have a terrible track record. We can do better ourselves, and already are.