idris-lang/Idris-dev — pull request #568 by LeifW (2013-10-30 02:59:56+00:00)
Title: Broaden localhost checking

* Broaden the check introduced in 229975d to account for
"localhost.localdomain" patterns.

Perhaps `isPrefixOf "localhost"` would be desireable, instead?

* Only bind to the localhost interface from REPL network socket.
Copied 'n pasted impl of
http://hackage.haskell.org/package/network-2.2.1.7/docs/Network.html#v:listenOn
modified to listen on localhost instead of iNADDR_ANY

Tested w/ netcat that I can connect when `host` is "localhost.localdomain", and that I can't when I try a non-127.0.0.1 interface on my local computer.