Jump to content
To block spammers, this forum has suspended new user registration ×
Comet Forums
To block spammers, this forum has suspended new user registration

"Add Peer" should allow hostnames


Recommended Posts

In my opinion, BitComet should allow hostname input (passing it to WinSock's resolver to obtain an IP address), rather than strictly IPv4-format IP addresses. Sometimes when manually adding a peer, they give you their hostname rather than their IP, which then has to manually resolved. These are computers, they should do the dirty work for us! B)

Note that the Add Peer functionality would have to be revamped a bit anyhow, if my IPv6 feature request were to be implemented. It would be great if multiple birds could be knocked out by the devs at once (i.e. lay the foundation for future IPv6 support with this request, even if it's not all there yet).

I envision the logic proceeding as follows:

Input starts with:

dotted decimal notation (all it currently accepts) - IPv4

colon-delimited hex pairs, enclosed by square brackets - IPv6

anything else - pass to resolver

Since Add Peer isn't a huge performance bottleneck, due to it not being used on a constant basis, I can't foresee the additional processing causing inconvenience for users (indeed, for IPv4 addresses, any slowdown would likely be imperceptible and any other address type is currently unsupported, so slow is better than not at all). The only side-effect I can think of is if the resolver takes a while to respond for a hostname, but I'm sure BitComet handles this already for resolving other things (such as trackers). :)

This is an issue as of BitComet 1.28.

Link to comment
Share on other sites

they give you their hostname rather than their IP

Why would a perspective peer give you a host name instead of an IP address?

The reason IP addresses are converted to names is to make something that can be recognized, remembered, and even spoken... but I can't think of why a peer would want to do this... I'm trying to picture a guy on a tv commercial saying "add me to your bittorrent clients, JohnSmith.org on port 45678 lol

Maybe there is cases where people do this, and you seem to be knowledgeable, so I'm willing to take your word for it, I just can't think of a reason to do that.

Link to comment
Share on other sites

For the great majority of people, IP addresses are temporarily leased from a provider, and are mutable. They are not ordinarily given a network name assignment along with the number, and there's no provision for asserting one to DNS. That is, they're simply not IN the DNS system at all.

Knowing that I'm at, or coming from, say, ATT.net won't help to resolve my address, because I don't have a name on their network -- "kluelos.att.net" won't authoritatively resolve to my actual IP address at any time.

Only in the rare circumstance where I have a static IP and a domain name to go with it, would this be of any assistance. That's going to be a *very* small number of people. I can't really see spending any coding time on it.

Link to comment
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
×
×
  • Create New...