Live data from Hacker News

The 7-bit Internet

blog.tabini.ca

51–60 of 162 posts

Re: The 7-bit Internet

#51
post #33
post #20

For some reason, I feel as though the people in this thread against text-based protocols have never used telnet to inspect or debug an HTTP request/response. Or used telnet to help develop a client for something like memcached. The ease of discoverability of a protocol should not be underrated.

Writing new protocol modules for tcpdump isn't difficult.

After that you can see what? You also have to use something like sed, xxd, and nc at least to make a request unless you are really good with bitfields and a hex editor. You want to keep a connection open or use what comes back for he next request? Maybe you can quickly cobble together a crude client in expect and tcl, perl, or python.

Re: The 7-bit Internet

#53
I think TLS/SSL is the elephant in the room here. A large part of the web is effectively already using binary protocol (HTTPS), and frankly I'd wish the part was even bigger.

Think of HTTP 2.0 as a successor for HTTPS instead of HTTP if it makes you feel better.

Re: The 7-bit Internet

#54

I don't get all the for-telnet arguments. Who uses telnet for this anyway? I'd bet that 90% of telnet-folk do: cake:~ mali$ telnet google.com 80 Trying 74.125.235.8... Connected to google.com. Escape character is '^]'. GET / HTTP/1.1 ....... HTTP/1.1 200 OK Date: Wed, 10 Jul 2013 22:25:02 GMT Expires: -1 Cache-Control: private, max-age=0 Content-Type: text/html; charset=ISO-8859-1 At which point they go "oh cool" and…

I'll give you two, both occurred to me in the past month:

1. Debugging which headers were causing Amazon CloudFront to MISS requests originating from Android. tcpdump, observe request, repeat using netcat until the problem was pinpointed.

2. Debugging failed authentication on a dovecot IMAP, on one specific scenario. Again, tcpdump, reproduce, isolate and fix.

Re: The 7-bit Internet

#56

I don't get all the for-telnet arguments. Who uses telnet for this anyway? I'd bet that 90% of telnet-folk do: cake:~ mali$ telnet google.com 80 Trying 74.125.235.8... Connected to google.com. Escape character is '^]'. GET / HTTP/1.1 ....... HTTP/1.1 200 OK Date: Wed, 10 Jul 2013 22:25:02 GMT Expires: -1 Cache-Control: private, max-age=0 Content-Type: text/html; charset=ISO-8859-1 At which point they go "oh cool" and…

Have you never had to send a specific request/response to a server? I've often found it easier to store the request in a text file and pipe it instead of using curl or another tool to craft it. When I was a webdev (over the past few years) I did this at least once a month. I'd daily look at the HTTP headers, though. Also, I'd often add custom headers for debugging purposes. Edit: It's also not just telnet, it's being…

Most likely all HTTP/2.0 servers will continue to support HTTP/1.1 forever, so you will still be able to do this.

Re: The 7-bit Internet

#57

I don't get all the for-telnet arguments. Who uses telnet for this anyway? I'd bet that 90% of telnet-folk do: cake:~ mali$ telnet google.com 80 Trying 74.125.235.8... Connected to google.com. Escape character is '^]'. GET / HTTP/1.1 ....... HTTP/1.1 200 OK Date: Wed, 10 Jul 2013 22:25:02 GMT Expires: -1 Cache-Control: private, max-age=0 Content-Type: text/html; charset=ISO-8859-1 At which point they go "oh cool" and…

You've never needed a basic TCP test without installing wget/nmap/etc? Most operating systems and hardware devices have telnet available for this kind of low-level troubleshooting.

You've never needed to test an SMTP connection to see what the rejection message was on the remote server (when a user can't get you the bounced message you require)?

You never wanted to see if an SSH port was open and what version was running?

Telnet is available in every router and firewall I have, I can't install curl onto a router to generate a request from a remote network, and I'll never see wget there either.

I do this stuff every day as part of my job, telnet is the go-to, the other utilities are fine, but they usually mask what I'm really looking for anyway, if they are even available on the platform I am using in the first place.

Re: The 7-bit Internet

#58
post #20

For some reason, I feel as though the people in this thread against text-based protocols have never used telnet to inspect or debug an HTTP request/response. Or used telnet to help develop a client for something like memcached. The ease of discoverability of a protocol should not be underrated.

I feel as though the people in this thread against (well-designed) binary protocols have never tried implementing a binary protocol. Length-prefixed fields and direct encoding of binary data go a long way to simplifying implementing a protocol. The ease of implementation of a simple binary protocol should not be underrated.

Easy to implement in C, perhaps, but not Python, PERL, and the ilk. Most importantly, it's not as easy to do it with a shell and nc to build a simple server.

Re: The 7-bit Internet

#59
post #20

For some reason, I feel as though the people in this thread against text-based protocols have never used telnet to inspect or debug an HTTP request/response. Or used telnet to help develop a client for something like memcached. The ease of discoverability of a protocol should not be underrated.

I feel as though the people in this thread against (well-designed) binary protocols have never tried implementing a binary protocol. Length-prefixed fields and direct encoding of binary data go a long way to simplifying implementing a protocol. The ease of implementation of a simple binary protocol should not be underrated.

It's not just the binary. It's that HTTP 2 is hugely more complex. Excessive complexity is a general engineering smell. It can't be all that difficult to implement a protocol for applying a few verbs to URIs.

Complex + non-discoverable = bad engineering

Re: The 7-bit Internet

#60
post #33
post #20

For some reason, I feel as though the people in this thread against text-based protocols have never used telnet to inspect or debug an HTTP request/response. Or used telnet to help develop a client for something like memcached. The ease of discoverability of a protocol should not be underrated.

Writing new protocol modules for tcpdump isn't difficult.

A lot more difficult than using netcat though.
Post reply on HN