likexian / whois

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

jp response #24

Closed davem14 closed 1 year ago

davem14 commented 2 years ago

The default whois response for .jp TLD (whois server: whois.jprs.jp) contains Japanese characters. It is really not readable and is not parsed well using likexian/whois-parser. Note: Adding the "/e" suffix to the query gives English charcters only.

example - google.jp vs google.jp/e: google.jp

[ JPRS database provides information on network administration. Its use is ] [ restricted to network administration purposes. For further information, ] [ use 'whois -h whois.jprs.jp help'. To suppress Japanese output, add'/e' ] [ at the end of command, e.g. 'whois -h whois.jprs.jp xxx/e'. ]

Domain Information: [ドメイン情報] [Domain Name] GOOGLE.JP

[登録者名] Google LLC [Registrant] Google LLC

[Name Server] ns1.google.com [Name Server] ns2.google.com [Name Server] ns3.google.com [Name Server] ns4.google.com [Signing Key]

[登録年月日] 2005/05/30 [有効期限] 2022/05/31 [状態] Active [最終更新] 2021/06/01 01:05:09 (JST)

Contact Information: [公開連絡窓口] [名前] Google LLC [Name] Google LLC [Email] dns-admin@google.com [Web Page]
[郵便番号] 94043 [住所] Mountain View 1600 Amphitheatre Parkway CA [Postal Address] Mountain View 1600 Amphitheatre Parkway CA [電話番号] 16502530000 [FAX番号] 16502530001

parsed using whois-parser: {"domain":{"domain":"google.jp","punycode":"google.jp","name":"google","extension":"jp","name_servers":["ns1.google.com","ns2.google.com","ns3.google.com","ns4.google.com"]},"registrant":{"name":"Google LLC"},"administrative":{"name":"Google LLC","street":"Mountain View, 1600 Amphitheatre Parkway, CA","email":"dns-admin@google.com"}}

google.jp/e:

[ JPRS database provides information on network administration. Its use is ] [ restricted to network administration purposes. For further information, ] [ use 'whois -h whois.jprs.jp help'. To suppress Japanese output, add'/e' ] [ at the end of command, e.g. 'whois -h whois.jprs.jp xxx/e'. ]

Domain Information: [Domain Name] GOOGLE.JP

[Registrant] Google LLC

[Name Server] ns1.google.com [Name Server] ns2.google.com [Name Server] ns3.google.com [Name Server] ns4.google.com [Signing Key]

[Created on] 2005/05/30 [Expires on] 2022/05/31 [Status] Active [Last Updated] 2021/06/01 01:05:09 (JST)

Contact Information: [Name] Google LLC [Email] dns-admin@google.com [Web Page]
[Postal code] 94043 [Postal Address] Mountain View 1600 Amphitheatre Parkway CA [Phone] 16502530000 [Fax] 16502530001

parsed using whois-parser: {"domain":{"domain":"google.jp","punycode":"google.jp","name":"google","extension":"jp","status":["active"],"name_servers":["ns1.google.com","ns2.google.com","ns3.google.com","ns4.google.com"],"created_date":"2005/05/30","updated_date":"2021/06/01 01:05:09 (JST)","expiration_date":"2022/05/31"},"registrant":{"name":"Google LLC"},"administrative":{"name":"Google LLC","street":"Mountain View, 1600 Amphitheatre Parkway, CA","postal_code":"94043","phone":"16502530000","fax":"16502530001","email":"dns-admin@google.com"}}

likexian commented 2 years ago

Hello @davem14 This is as expected, for .jp, please try:

whois -j google.jp/e