Rust crate that can be used to parse the registry. The project includes binary applications which can be found in src/bin/

Yamakaja f7c4a285bb Fix lines prefixed by '+' 2 years ago
src f7c4a285bb Fix lines prefixed by '+' 2 years ago
.gitignore 5d04f1133d Initial commit 3 years ago
Cargo.lock f7c4a285bb Fix lines prefixed by '+' 2 years ago
Cargo.toml 279f48c54e Add roasrv, a datasource for cloudflares gortr 3 years ago
LICENSE ad2303cad2 Add license 3 years ago 66ef75a850 Add; Add registry path parameter to roagen 3 years ago


Regparse consists of two parts, a library and multiple application binaries.


To compile everything just run the following:

cargo build --release


In this section i'll describe all the application binaries which can be found in src/bin/.


A "testing" / "debug" binary which is mostly used for parser validation since it just parses the entire registry and then exits.


A small application that parses the routes and prints them in the config syntax for ROA validation by bird (2.x - support for bird 1.x can be achieved by piping the output through sed 's/route/roa/g').

Example output:

route max 29 as 64858;
route max 29 as 4242420049;
route max 32 as 64654;
route max 32 as 4242422718;
route max 32 as 4242422480;
route max 29 as 64737;
route max 29 as 65210;
route max 29 as 76175;
route max 29 as 4242421987;
route max 29 as 4242422684;
route fdfc:3e4f:f3c0::/48 max 64 as 4242420020;
route fd42:830:420::/48 max 64 as 4242420203;
route fd42:4242:23::/48 max 64 as 4242420510;
route fd42:2950:202::/48 max 64 as 4242422950;
route fd42:2950:202::/48 max 64 as 202265;
route fd14:b4dc:4b1e::/64 max 64 as 65052;
route fdec:c0f1:afda::/64 max 64 as 65115;
route fda0:bbe1:38d::/48 max 64 as 4242420160;
route fdfe:1647:a2bb::/48 max 64 as 4242421978;
route fd23:dead:beef::/48 max 64 as 65432;


roasrv serves a similar purpose to roagen, but it's slightly more complex: roasrv in conjunction with CloudFlares gortr can be used to perform ROA validation using the RPKI-to-Router protocol. For this, roasrv performs the following tasks:

  • roasrv will regularly pull updates to a local (git) copy of the dn42 registry, and re-parse it if it detects a change
  • The parsed data is then converted into a json string which is made accessible to gortr using a builtin webserver

See the Yamakaja/roasrv-pkg repository for instructions on how to setup roasrv with gortr

Example data:

  "roas": [
      "prefix": "",
      "maxLength": 29,
      "asn": "AS65079"
      "prefix": "",
      "maxLength": 29,
      "asn": "AS65530"
      "prefix": "fdff:feed:c0de::/48",
      "maxLength": 64,
      "asn": "AS4242420138"
      "prefix": "fd42:c066:e081::/48",
      "maxLength": 64,
      "asn": "AS4242420092"