likexian / whois

Whois client for domain and ip whois information query in Go(Golang).
Apache License 2.0
400 stars 74 forks source link

Cannot specify servers using non-standard ports #47

Closed gavincarr closed 1 month ago

gavincarr commented 1 month ago

Thanks for this module!

I'm using the client.Whois(query, server) call, but I've come across servers that aren't running on the default port e.g. rwhois.shawcable.net:4321.

There doesn't seem to be a way to specify an explicit server with a non-default port right now, correct?

Would you be open to a pull request to allow the server string to have an optional trailing port? (maybe a bit hacky?)

Or would you prefer a new Whois function with explicit (query, server string, port int) arguments?

Thanks, Gavin

likexian commented 1 month ago

Hello @gavincarr PR is welcome. It seems that port in server string is more compatible.


If you think this repository is helpful, please share it with friends, thanks.