News for hackers. Stuff that matters.
Re:Blocking website ads with a hosts file by voyager2 on Wednesday January 23, 2019 @09:30AM (#18978357)
"0.0.0.0 is the invalid, un-routable address."

  That's apparently a windows-centric statement.  In Linux,
0.0.0.0 is the same as 127.0.0.1, whereas 0.0.0.1 works as your invalid address.
Re:Blocking website ads with a hosts file by boomlinde on Wednesday January 23, 2019 @10:19AM (#18978831)
It's true both in Windows and Linux that it's a non-routable address. It's false both in Windows and Linux that it's an invalid address. It's also false that 0.0.0.0 is "the same as 127.0.0.1" in general. That it's a valid but non-routable address makes it a good address for applications to assign a special purpose to. You'll find that in some cases 0.0.0.0 means localhost, but in other cases it has other meanings.

For example, you might be in for a nasty surprise if you assume that "nc -l 0.0.0.0 1234" is equivalent to "nc -l 127.0.0.1 1234".

Re:Blocking website ads with a hosts file by upofadown on Wednesday January 23, 2019 @10:05AM (#18978697)
By golly, Linux does map 0.0.0.0 to localhost. That produced a bunch of searches to try to find out why it does that. Nothing found. At this point I strongly suspect that Linux is simply exhibiting incorrect behaviour...

It does it for :: as well...

Re:Blocking website ads with a hosts file by benkillin on Wednesday January 23, 2019 @09:27PM (#18985486)
0.0.0.0 is the address programs will listen on to be able to respond to any IP address assigned to the system.

When you are setting up a socket to listen for connections on a particular port you would specify 0.0.0.0 so then things can connect from anywhere like localhost or on any of the many possible IP addresses assigned to the machine, or you can specify a particular IP address and only be able to get traffic from that. For example if you wanted a program only reachable from the same machine you could listen on localhost (127.0.0.1) and then nothing external could directly connect to that particular service.

Re:Blocking website ads with a hosts file by 1201alarm on Wednesday January 23, 2019 @11:32AM (#18979699)
I've used "telnet 0", for example, as a quick path to localhost on Linux for decades.