Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fails for network with multiple countries #21

Closed
toreanderson opened this issue Nov 1, 2016 · 5 comments
Closed

Fails for network with multiple countries #21

toreanderson opened this issue Nov 1, 2016 · 5 comments

Comments

@toreanderson
Copy link

The console output below probably says it all:

$ bin/nicinfo 2a02:c0::
# NicInfo v.1.1.1 EXPERIMNETAL
# Error 400.

[ NOTICE ] Terms and Conditions
         1 This is the RIPE Database query service. The objects are in RDAP format.
       TOS http://www.ripe.net/db/support/db-terms-conditions.pdf

 [ ERROR ] Multiple country: found in 2a02:c0::/48
      Code 400
/local/home/tore/git/nicinfo/lib/nicinfo/error_code.rb:34:in `display_error_code': undefined method `each' for nil:NilClass (NoMethodError)
        from /local/home/tore/git/nicinfo/lib/nicinfo/nicinfo_main.rb:847:in `handle_error_response'
        from /local/home/tore/git/nicinfo/lib/nicinfo/nicinfo_main.rb:749:in `rescue in do_rdap_query'
        from /local/home/tore/git/nicinfo/lib/nicinfo/nicinfo_main.rb:712:in `do_rdap_query'
        from /local/home/tore/git/nicinfo/lib/nicinfo/nicinfo_main.rb:499:in `run'
        from bin/nicinfo:25:in `<main>'
@toreanderson
Copy link
Author

Nevermind, this error originates from the RIPE RDAP service:

$ curl https://rdap.db.ripe.net/ip/2a02:c0::
{
  "links" : [ {
    "value" : "http://www.ripe.net/data-tools/support/documentation/terms",
    "rel" : "copyright",
    "href" : "http://www.ripe.net/data-tools/support/documentation/terms"
  } ],
  "rdapConformance" : [ "rdap_level_0" ],
  "notices" : [ {
    "title" : "Terms and Conditions",
    "description" : [ "This is the RIPE Database query service. The objects are in RDAP format." ],
    "links" : [ {
      "rel" : "terms-of-service",
      "href" : "http://www.ripe.net/db/support/db-terms-conditions.pdf",
      "type" : "application/pdf"
    } ]
  } ],
  "port43" : "whois.ripe.net",
  "errorCode" : 400,
  "title" : "Multiple country: found in 2a02:c0::/48"
}

Apologies for the noise.

(By the way, you might want to fix that EXPERIMNETAL typo.)

@anewton1998
Copy link
Contributor

No trouble at all. :)

@timbru
Copy link

timbru commented Nov 7, 2016

Hi Tore, all... we are looking into this.

In a nutshell we have a number (1000s) of objects that have more than one country code, and the current RDAP specification only allows one.

Throwing an error is not the best. However, we are not sure what would be. Picking just one CC would solve the immediate problem - but it's pretty random. Allowing multiple CCs would require a change to the RDAP standards - so would need discussion in the IETF.

I plan to discuss with some people at the next IETF and see what the best path is. But, for the moment we don't have a solution.

@ghost
Copy link

ghost commented Feb 6, 2017

for the moment we don't have a solution.

Might be worth re-opening this issue, then?

I plan to discuss with some people at the next IETF and see what the best path is.

Cool, thanks for that :)

@mcorb
Copy link

mcorb commented Sep 3, 2018

This issue is causing parts of the IP address space to go dark in tools using whois-rdap. And without a valid startAddress and endAddress it also means clients have no way to cache the failed response, so they end up hammering the server.

Would it be possible to return a minimally valid fallback RDAP in the error message body so that clients can choose to cache the invalid IP range, pending a proper solution?

Returning just one country and adding the other to the notices would also be fine.

mcorb pushed a commit to ntblk/whois-rdap that referenced this issue Sep 6, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants