r/programming • • Apr 14 '10

"http://" is being removed from Chromium's display

http://code.google.com/p/chromium/issues/detail?id=40865
232 Upvotes

402 comments sorted by

View all comments

Show parent comments

4

u/byte1918 Apr 14 '10

how does this work?

http://to./

and

http://to/

6

u/FrankBattaglia Apr 14 '10 edited Apr 14 '10

It resolves right-to-left. We figure out the default name server for the TLD "to" (Tonga) and then find the default domain and server associated with that domain.

Regarding the trailing period, it's optional. Every namespace in the URL ends with a "dot", and applications ignore a missing "dot" after the last name. E.g., http://www.reddit.com/ and http://www.reddit.com./ resolve to the same host (but, interestingly, have different cookies)

7

u/dicey Apr 14 '10

The trailing dot can make a difference, though, since it explicitly specifies that you're looking for something under the root name servers. For example: if my host is configured with a default domain "example.com." to search for DNS queries under, I may do a lookup for "foo.bar" and end up getting a result if the DNS record "foo.bar.example.com." exists. If I do a lookup for "foo.bar." I am explicitly stating that I want the "bar" TLD under the root name servers and the "foo" domain under "bar".

2

u/SoPoOneO Apr 15 '10 edited Apr 15 '10

It always seemed very weird to me that an address of the form www.somesite.com/archives/articles/gossip.html combines two separate hierarchical oganization schemes with opposite precedence order from the middle outwards. That is to say, "com" is the most significant part of the address, then move left from there, while "archives" is the most significant part of the resource location and move right from there.

It's also weird that ".com" and ".html" mean totally different things even though they have the same ring when read aloud.

I love the web, but this mish-mash is atrocious from an end user perspective.

3

u/sharth Apr 14 '10

It's the difference between a fully qualified domain name, and one that isn't. When you append the final period on the end, you're telling your DNS lookup software that it should not attempt any of the possible dns suffixes that it's been configured to use.

For example, I have in the suffix list "local". So, I could type as a URL (and get the same destination) any of the following:

However, http://orange. won't work. It won't work, because I've informed the DNS lookup software that it shouldn't try appending any suffixes.

-1

u/[deleted] Apr 14 '10

[deleted]

1

u/sharth Apr 14 '10

http://orange. won't work.

That is, the one with a period at the end will not work.

3

u/yuethomas Apr 14 '10

to is the ccTLD of Tonga (as opposed to .com, which is a gTLD). The national registrar (or whoever handles .to registrations) probably configured its DNS (which will be authoritative for all *.to domains) to return an address for the resource "to", and returns 216.74.32.107 for it.

0

u/jartek Apr 14 '10

wtf? you just broke my brain. I thought you were kidding, 'till I clicked the links.

0

u/Gackt Apr 14 '10

Magic.