From Sean.Zhao at CenturyLink.com Mon Dec 1 15:59:45 2014 From: Sean.Zhao at CenturyLink.com (Zhao, Sean) Date: Mon, 1 Dec 2014 20:59:45 +0000 Subject: [arin-tech-discuss] why do I have error 400 bad request reuturned? Message-ID: Hi All, Instead of checking the start ip and end ip, like http://whois.ote.arin.net/rest/ip/65.127.10.160 and http://whois.ote.arin.net/rest/ip/65.127.10.191, do you have something like http://whois.ote.arin.net/rest/ip /65.127.10.160/maskNo/27? So we can check if the netBlock is swiped in one call instead checking by ip addresses for 32 times. In this case of mine, checking only 65.127..160 and 65.127.10.191 is not good enough because both ips are not swiped, but there are 8 ips, 65.127.10.176 - 65.127.10.183 are swiped. They are between the ip 65.127..160 and 65.127.10.191. So if you have a netBlock checking, it would be great for me. Thanks Sean Zhao sean.zhao at centurylink.com This communication is the property of CenturyLink and may contain confidential or privileged information. Unauthorized use of this communication is strictly prohibited and may be unlawful. If you have received this communication in error, please immediately notify the sender by reply e-mail and destroy all copies of the communication and any attachments. -------------- next part -------------- An HTML attachment was scrubbed... URL: From andy at arin.net Tue Dec 2 12:28:07 2014 From: andy at arin.net (Andy Newton) Date: Tue, 2 Dec 2014 17:28:07 +0000 Subject: [arin-tech-discuss] why do I have error 400 bad request reuturned? In-Reply-To: References: Message-ID: <1BD84DF9-7A14-4E94-87BD-254F02EDFF0B@arin.net> Sean, Yes there is a way to do that. Depending on the logic you are using, /cidr/xxx.xxx.xxx.xxx/yy[/more|less] queries are probably what you are looking for. For instance, http://whois.arin.net/rest/cidr/192.149.252.0/24/more will list the networks more specific to the CIDR given. /more gives you a list of networks more specific, /less gives you a list of networks less specific, and if you do not use either it will return a network if it is exactly matching the CIDR. The documentation for that query is here: https://www.arin.net/resources/whoisrws/whois_api.html#whoisrws under section 4.4.3. I hope that helps. Andy Newton, Chief Engineer, ARIN On Dec 1, 2014, at 3:59 PM, Zhao, Sean > wrote: Hi All, Instead of checking the start ip and end ip, likehttp://whois.ote.arin.net/rest/ip/65.127.10.160 and http://whois.ote.arin.net/rest/ip/65.127.10.191, do you have something likehttp://whois.ote.arin.net/rest/ip /65.127.10.160/maskNo/27? So we can check if the netBlock is swiped in one call instead checking by ip addresses for 32 times. In this case of mine, checking only 65.127..160 and 65.127.10.191 is not good enough because both ips are not swiped, but there are 8 ips, 65.127.10.176 - 65.127.10.183 are swiped. They are between the ip 65.127..160 and 65.127.10.191. So if you have a netBlock checking, it would be great for me. Thanks Sean Zhao sean.zhao at centurylink.com This communication is the property of CenturyLink and may contain confidential or privileged information. Unauthorized use of this communication is strictly prohibited and may be unlawful. If you have received this communication in error, please immediately notify the sender by reply e-mail and destroy all copies of the communication and any attachments. _______________________________________________ arin-tech-discuss mailing list arin-tech-discuss at arin.net http://lists.arin.net/mailman/listinfo/arin-tech-discuss -------------- next part -------------- An HTML attachment was scrubbed... URL: From Sean.Zhao at CenturyLink.com Tue Dec 2 14:27:16 2014 From: Sean.Zhao at CenturyLink.com (Zhao, Sean) Date: Tue, 2 Dec 2014 19:27:16 +0000 Subject: [arin-tech-discuss] why do I have error 400 bad request reuturned? In-Reply-To: <1BD84DF9-7A14-4E94-87BD-254F02EDFF0B@arin.net> References: <1BD84DF9-7A14-4E94-87BD-254F02EDFF0B@arin.net> Message-ID: This is exactly what I need!!! Thanks a lot!!! You guys have a great holiday season!!!!! Thanks Sean Zhao sean.zhao at centurylink.com From: Andy Newton [mailto:andy at arin.net] Sent: Tuesday, December 02, 2014 12:28 PM To: Zhao, Sean Cc: arin-tech-discuss at arin.net; Talavagalu Matha Ajjaiah, Chandrasekhara; Grimes, Ronald Subject: Re: [arin-tech-discuss] why do I have error 400 bad request reuturned? Sean, Yes there is a way to do that. Depending on the logic you are using, /cidr/xxx.xxx.xxx.xxx/yy[/more|less] queries are probably what you are looking for. For instance, http://whois.arin.net/rest/cidr/192.149.252.0/24/more will list the networks more specific to the CIDR given. /more gives you a list of networks more specific, /less gives you a list of networks less specific, and if you do not use either it will return a network if it is exactly matching the CIDR. The documentation for that query is here: https://www.arin.net/resources/whoisrws/whois_api.html#whoisrws under section 4.4.3. I hope that helps. Andy Newton, Chief Engineer, ARIN On Dec 1, 2014, at 3:59 PM, Zhao, Sean > wrote: Hi All, Instead of checking the start ip and end ip, likehttp://whois.ote.arin.net/rest/ip/65.127.10.160 and http://whois.ote.arin.net/rest/ip/65.127.10.191, do you have something likehttp://whois.ote.arin.net/rest/ip /65.127.10.160/maskNo/27? So we can check if the netBlock is swiped in one call instead checking by ip addresses for 32 times. In this case of mine, checking only 65.127..160 and 65.127.10.191 is not good enough because both ips are not swiped, but there are 8 ips, 65.127.10.176 - 65.127.10.183 are swiped. They are between the ip 65.127..160 and 65.127.10.191. So if you have a netBlock checking, it would be great for me. Thanks Sean Zhao sean.zhao at centurylink.com This communication is the property of CenturyLink and may contain confidential or privileged information. Unauthorized use of this communication is strictly prohibited and may be unlawful. If you have received this communication in error, please immediately notify the sender by reply e-mail and destroy all copies of the communication and any attachments. _______________________________________________ arin-tech-discuss mailing list arin-tech-discuss at arin.net http://lists.arin.net/mailman/listinfo/arin-tech-discuss This communication is the property of CenturyLink and may contain confidential or privileged information. Unauthorized use of this communication is strictly prohibited and may be unlawful. If you have received this communication in error, please immediately notify the sender by reply e-mail and destroy all copies of the communication and any attachments. -------------- next part -------------- An HTML attachment was scrubbed... URL: