Skip to main content

ARINREST LIB

The purpose of this package is to manage and query resources hosted by ARIN. ARIN has 3 different services that you can query and manage records on.

  • whois, only the RDAP interface is supported by this library
  • IRR, This still needs to be implemented
  • RPKI, The reason I start this library os to manage ROA objects hosted in ARINs repository.

Usage

The entry point into this library is the ArinRest class. The class only takes an API Key from ARIN to instantiate.

from arinrest import ArinRest
from arinrest.rpki import ROA

arinclient = ArinRest('your-api-key-here')

# arinclient.rdap() creates a rdap session with ARIN
whois_client = arinclient.rdap()

# You can manage resources in the IRR and RPKI endpoints so currently the classes
# require an API key to instantiate them.

# create an rpki session with signing capabilities, private key required
rpki_client = arin.rpki("/path/to/private/key")

# add a ROA to the queue to be submitted as well as signing it.
rpki_client.add_roa(roa: ROA)

# submit the ROA to ARIN
rpki_clinet.submit_roas()

TODO

Break out the rpki client and the ROA object into 2 separate classes.

- ROA object will have getters and setters for the attributes with validation of values.

  • rpki client will have the connection and url's needed to submit and fetch information about ROAs.

  • ARIN may have created certificate with the wrong public key in it that is used to identify the resources we have the right to manage.

    • Certificate creation ticket ARIN-20221019-X541735

      • The public key in this ticket is the same as the stored key in pwdb
      • I have used the key pair to sign a message and verify the signature locally
      • The public key in the ticket does not match the public key in the x.509 certificate.
      • When submitting an ROA request it complains about a bad Public Key.
          <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
          <error xmlns="http://www.arin.net/regrws/core/v1">
              <additionalInfo/><code>E_ENTITY_VALIDATION</code>
              <components>
                  <component>
                      <message>The public key you entered is invalid.</message>
                      <name>signedRoaRequest</name>
                  </component>
              </components>
              <message>Payload entity failed to validate; see component messages for details.</message>
          </error>
      

Resources

Manually signed ROA: Implemented in Python ARIN Manually signed ROA

RSA Signing with cryptography python lib RSA

Metadata

Release files for arinrest-client 0.3.5

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for arinrest-client 0.3.5
File Size Uploaded
arinrest-client-0.3.5.tar.gz 13.5 kB Details

Release files / arinrest-client-0.3.5.tar.gz

Download URL arinrest-client-0.3.5.tar.gz
Size 13.5 kB
Tags Source
SHA-256 checksum
How to use checksums
3881e11ba2b8ae77c48e0cefd16b063102cfc880b9bcc163d178a3d652463ac7
BLAKE2b-256 checksum
How to use checksums
0d76108fe3f8102cb8ed34473cc02d7c1d48fd1287c7edaa3747be3b7b379eab
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.2 CPython/3.10.7

Release history Release notifications | RSS feed

This release

0.3.5 This release

1 release file

0.3.4

1 release file

0.3.3

1 release file

0.3.1

1 release file

0.3

1 release file

0.2.1

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page