Live data from Hacker News

I Got Sick of Remembering Port Numbers

gregraiz.com

121–130 of 171 posts

Re: I Got Sick of Remembering Port Numbers

#121
post #46

Earlier quoted context omitted.

As bandie pointed out, you‘re explicitly making a http request. Duh. nc is for generic connections and handles it well.

i know, but the OP's goal was to host/access http(s) services with names and avoid port numbers, and gopher service name was chosen by me as an example. my point was that /etc/services cannot be used for the OP's need. if you host an http(s) service on port 11111 you can reach it with url http://127.1:11111 , but url http://127.1:vce/ would not work in most software. $ grep 11111 /etc/services vce 11111/udp # Viral C…

But if you want to contact vce, why use „http“? It‘s not going to work

Re: I Got Sick of Remembering Port Numbers

#123

This is really amusing. Because absolutly eveyrone I know vibe-coded this thing. I think the first one was https://github.com/ralt/dns-to-port possibly mine is second (but it is very much a joke so I am not linking it) .. Vercel later did https://github.com/vercel-labs/portless and I would imagine quite a few others. Zeitgeist. Also this does probably mean its kinda useful. And that none of us can get bothered to "Go…

> a spaced repetition thing

anki?...

Re: I Got Sick of Remembering Port Numbers

#124

Earlier quoted context omitted.

And there's also .local for mDNS on local network! I've also come across projects using a public DNS record that points to 127.0.0.1 (something like localtest.me?). IMO that's way worse than using .localhost since you're trusting some rando not to change the DNS records and exfiltrate your meant-to-be-local traffic.

I did not mention .local, because it is covered in the linked articles: a special-use TLD, reserved for a certain purpose. It has often happened that LAN admins try to name something under ".local" and configure a zone for it in their BIND server. But this is incorrect, because ".local" is already managed by the zeroconf/mDNS protocols. It is a special case; and that is what ".internal" seeks to rectify, by giving y'…

I've used[0] `.local` to achieve something like this, by advertising service endpoints over mDNS.

Exposing random services to your local network is exactly what mDNS is for, I always thought it was a shame more dev tooling didn't do that.

[0]: https://github.com/andrewaylett/mod_bonjour is a fork of Apple's mod_bonjour, very much unloved of late I'm afraid.

Re: I Got Sick of Remembering Port Numbers

#125
post #71

Earlier quoted context omitted.

Top reply, and clearly based on the article's title rather than its content, as are the follow-ups. You're making this site worse. The article is short; go read it then come back and delete.

Sounds like more of a problem with the title than the person you're attempting to insult.

[dead]

Re: I Got Sick of Remembering Port Numbers

#127

Earlier quoted context omitted.

ipv6 packet does not have any port field. ports are on the level of tcp and udp, and you don't have to use tcp or udp on top of ipv6. ipv4 packet does not have any port information as well.

> ipv6 packet does not have any port field Yes, that's why I said I know it was mixing of layers. However ports are a layer violation in a strict sense, introduced as a workaround because there was no easy way to just add thousands of new IPs to a single host back in the IPv4 days. No need to continue a workaround that causes grief on a daily basis.

What do you mean? You’ll still have to use TCP or UDP over IPv6, and both of those protocols use ports. Nothing is stopping you from creating a transport protocol that doesn’t use ports if you want to, but that has nothing to do with the network layer.

Re: I Got Sick of Remembering Port Numbers

#128
post #123

This is really amusing. Because absolutly eveyrone I know vibe-coded this thing. I think the first one was https://github.com/ralt/dns-to-port possibly mine is second (but it is very much a joke so I am not linking it) .. Vercel later did https://github.com/vercel-labs/portless and I would imagine quite a few others. Zeitgeist. Also this does probably mean its kinda useful. And that none of us can get bothered to "Go…

> a spaced repetition thing anki?...

I do exactly this for the half dozen or so ports that I do care to remember.
Post reply on HN