Wikipedia states that underscores are used by both Android and Microsoft Windows Systems in hostnames. My question is, what are these host names? Do you have examples of these strange hostnames names and what they are used for?
Valid characters for hostnames are ASCII(7) letters from a to z, the digits from 0 to 9, and the hyphen (-). A hostname may not start with a hyphen. Hostnames are often used with network client and server programs, which must generally translate the name to an address for use.
A host name is used when a web client makes an HTTP request to a host. The user making the request can specify the IP address of the server rather than the host name, but that is now unusual on the Internet. Host names are more convenient for users than numeric IP addresses.
Underscore characters are not permitted in domain names in accordance with RFC 1035, which only allows letters, digits and hyphens. As such, you cannot register a domain name with an underscore character.
What are host names?
Analogous to a school class room where each student has a roll number/id so that he/she is identified, in the class room of Internet (or for that matter any computer network) each device that are in the network needs to be uniquely identified. This is done via a Host Name. Thus hostnames are names that helps in identifying devices in a network.
Hostnames with underscore(_) character.
During the period when the standards were being laid for the valid and invalid hostnames
, the common terminal interface was the keyboard of the Teletype (TTY) ASR-33. Now this keyborad never had a underscore(_) key in it (check this pic http://www.pdp8.net/asr33/pics/kbd_top.shtml?large) and hence it was not possible to have a hostname
with an underscore(_) in it. Check this link for more details: http://www.quora.com/Domain-Name-System-DNS/Why-are-underscores-not-allowed-in-DNS-host-names
Underscore(_) character can be used in the domain names. As this post states Can (domain name) subdomains have an underscore "_" in it? it is completely valid to have an underscore. Some examples(as shown in the post) are _jabber._tcp.gmail.com
or _sip._udp.apnic.net
. Another example of usage of an underscore is seen here http://ideaharbor.org/notes/technical/enabling-chat-outside-google-apps. Though its valid to use underscores it not a recommended practice.
The wikipedia link in your post states that Microsoft Windows and Android smartphones does not enforce the rule against using an underscore in hostnames. Non enforcement of this rule may result in problems because many systems reject such kind of hostnames.
Hope you get something out of this explanation.
EDIT
On further investigation on the issue, I came upon this wonderful post which I suppose clarifies the usage of underscore in hostnames:
http://networkadminkb.com/KB/a156/windows-2003-dns-and-the-underscore.aspx
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With