hints:rpki
Differences
This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
hints:rpki [2024/07/31 05:42] – [IOS-XR Configuration with Validator] philip | hints:rpki [2025/05/04 23:24] (current) – [Building rpki-client] philip | ||
---|---|---|---|
Line 14: | Line 14: | ||
* [[rpki# | * [[rpki# | ||
* [[rpki# | * [[rpki# | ||
+ | * [[rpki# | ||
* [[rpki# | * [[rpki# | ||
* [[rpki# | * [[rpki# | ||
* [[rpki# | * [[rpki# | ||
- | The tips and tricks for the validator builds discussed below all are for Ubuntu | + | The tips and tricks for the validator builds discussed below all are for Ubuntu |
===== AS0 TALs ===== | ===== AS0 TALs ===== | ||
Line 31: | Line 32: | ||
===== NLnetLabs Routinator ===== | ===== NLnetLabs Routinator ===== | ||
- | Nothing to say here, the instructions just work, the validator installs sweetly, and just runs. As long as the instructions are followed. The current version of Routinator is 0.14.0, at time of writing. | + | Nothing to say here, the instructions just work, the validator installs sweetly, and just runs. As long as the instructions are followed. The current version of Routinator is 0.14.2, at time of writing. |
If using Debian/ | If using Debian/ | ||
Line 85: | Line 86: | ||
===== FORT ===== | ===== FORT ===== | ||
- | FORT is the validator developed by NIC Mexico. More about it is on the [[https:// | + | FORT is the validator developed by NIC Mexico. More about it is on the [[https:// |
- | FORT is available as part of Ubuntu 22.04 packaging, but it is an older version (1.5.3-1), so for this reason we use the latest NIC Mexico produced package. | + | FORT is available as part of Ubuntu 22.04 packaging, but it is an older version (1.5.3-1). Likewise |
FORT is not quite so easy to install, but still relatively simple as long as you follow the instructions on their [[https:// | FORT is not quite so easy to install, but still relatively simple as long as you follow the instructions on their [[https:// | ||
Line 94: | Line 95: | ||
< | < | ||
- | wget https:// | + | wget https:// |
</ | </ | ||
and then install it: | and then install it: | ||
< | < | ||
- | sudo apt install ./fort_1.6.2-1_amd64.deb | + | sudo apt install ./fort_1.6.6-1_amd64.deb |
</ | </ | ||
Line 150: | Line 151: | ||
and it should run successfully. You should see something like this when you run **systemctl status fort**: | and it should run successfully. You should see something like this when you run **systemctl status fort**: | ||
< | < | ||
- | * fort.service - FORT RPKI validator | + | ● fort.service - FORT RPKI validator |
- | | + | |
- | Drop-In: / | + | |
- | | + | |
- | | + | |
Docs: man:fort(8) | Docs: man:fort(8) | ||
| | ||
- | Main PID: 3100 (fort) | + | Main PID: 148150 |
- | Tasks: | + | Tasks: |
- | | + | |
+ | CPU: 27.801s | ||
| | ||
- | | + | |
+ | |||
+ | Oct 07 22:58:03 fort systemd[1]: Started fort.service - FORT RPKI validator. | ||
</ | </ | ||
You can check by using **ps ax** to get: | You can check by using **ps ax** to get: | ||
Line 258: | Line 260: | ||
sudo make install | sudo make install | ||
</ | </ | ||
- | which will install the client in **/ | + | which will install the client in **/ |
- | < | + | |
- | wget https://www.arin.net/resources/ | + | |
- | sudo mv arin.tal /etc/rpki | + | |
- | </ | + | |
Now the client can be run. There is no daemon option, it simply runs at the command line, and when it has finished downloading all the VRPs (around 10-15 minutes depending on bandwidth) it exits. But that's okay. Try running the client: | Now the client can be run. There is no daemon option, it simply runs at the command line, and when it has finished downloading all the VRPs (around 10-15 minutes depending on bandwidth) it exits. But that's okay. Try running the client: | ||
< | < | ||
Line 280: | Line 279: | ||
</ | </ | ||
and that's it. Every hour, cron will run **rpki-client** which will produce JSON output of all the VRPs it has collected. As noted above, JSON output is what is used by StayRTR and GoRTR as their input sources. Make sure that the **/ | and that's it. Every hour, cron will run **rpki-client** which will produce JSON output of all the VRPs it has collected. As noted above, JSON output is what is used by StayRTR and GoRTR as their input sources. Make sure that the **/ | ||
+ | |||
+ | If you would like to include the [[https:// | ||
+ | < | ||
+ | / | ||
+ | </ | ||
It's a good idea to check the log file in case **rpki-client** reports issues trying to write local files etc. But mostly what you'll see there are all the transactions with the various CAs, and the problems encountered (there will be lots, unfortunately). | It's a good idea to check the log file in case **rpki-client** reports issues trying to write local files etc. But mostly what you'll see there are all the transactions with the various CAs, and the problems encountered (there will be lots, unfortunately). | ||
Line 288: | Line 292: | ||
StayRTR is a hard fork of GoRTR (which is no longer maintained by Cloudflare and is badly out of date). For this reason, I **strongly** recommend you use StayRTR rather than GoRTR. If you have an existing GoRTR install, simply replace it with StayRTR. | StayRTR is a hard fork of GoRTR (which is no longer maintained by Cloudflare and is badly out of date). For this reason, I **strongly** recommend you use StayRTR rather than GoRTR. If you have an existing GoRTR install, simply replace it with StayRTR. | ||
- | StayRTR has now been packaged and is available as part of the Ubuntu 22.04 distribution. However, the packaged version is old (version | + | StayRTR has now been packaged and is available as part of the Ubuntu 22.04 distribution |
So for this reason, and to stay up to date, at least on Ubuntu, we have to build it ourselves. A pity that the **StayRTR** maintainers don't build their own deb package, or pre-build packages like NLnetLabs do with Routinator. | So for this reason, and to stay up to date, at least on Ubuntu, we have to build it ourselves. A pity that the **StayRTR** maintainers don't build their own deb package, or pre-build packages like NLnetLabs do with Routinator. | ||
Line 296: | Line 300: | ||
First you will need a working Go environment. Full instructions are at [[https:// | First you will need a working Go environment. Full instructions are at [[https:// | ||
- | First off, download the latest Go package (1.22.5 at time of writing): | + | First off, download the latest Go package (1.24.1 at time of writing): |
< | < | ||
- | wget https:// | + | wget https:// |
</ | </ | ||
If you have an existing Go environment, | If you have an existing Go environment, | ||
Line 308: | Line 312: | ||
cd /usr/local | cd /usr/local | ||
sudo chmod 777 . | sudo chmod 777 . | ||
- | tar xzf ~/go1.22.5.linux-amd64.tar.gz | + | tar xzf ~/go1.24.1.linux-amd64.tar.gz |
sudo chmod 755 . | sudo chmod 755 . | ||
</ | </ | ||
Line 338: | Line 342: | ||
< | < | ||
cd dist | cd dist | ||
- | sudo cp -p stayrtr-v0.5.1-50-gbf5793c-linux-x86_64 / | + | sudo cp -p stayrtr-v0.6.2-linux-x86_64 / |
- | sudo cp -p rtrdump-v0.5.1-50-gbf5793c-linux-x86_64 / | + | sudo cp -p rtrdump-v0.6.2-linux-x86_64 / |
- | sudo cp -p rtrmon-v0.5.1-50-gbf5793c-linux-x86_64 / | + | sudo cp -p rtrmon-v0.6.2-linux-x86_64 / |
</ | </ | ||
Line 422: | Line 426: | ||
and you should see something like this: | and you should see something like this: | ||
< | < | ||
- | * stayrtr.service - StayRTR RPKI to Router Server | + | ● stayrtr.service - StayRTR RPKI to Router Server |
- | | + | |
- | | + | |
- | Docs: https:// | + | Docs: https:// |
- | Tasks: | + | Main PID: 44045 (stayrtr) |
+ | Tasks: | ||
+ | Memory: | ||
+ | CPU: 3.805s | ||
| | ||
- | | + | |
- | Jan 28 15:50:27 stayrtr | + | |
- | Jan 28 15:50:27 stayrtr | + | Aug 15 16:57:06 rpki systemd[1]: Starting |
- | Jan 28 15:50:27 stayrtr | + | Aug 15 16:57:07 rpki systemd[1]: Started |
- | Jan 28 15:50:28 stayrtr | + | Aug 15 16:57:10 rpki stayrtr[44045]: time="2024-08-15T16:57:10+06:00" level=info |
- | Jan 28 15:50:29 stayrtr | + | Aug 15 16:57:11 rpki stayrtr[44045]: time="2024-08-15T16:57:11+06:00" level=info |
- | Jan 28 15:50:29 stayrtr stayrtr[17390]: | + | Aug 15 16:57:11 rpki stayrtr[44045]: time="2024-08-15T16:57:11+06:00" level=info |
</ | </ | ||
and you can also run the more traditional **ps ax** to see something like: | and you can also run the more traditional **ps ax** to see something like: | ||
< | < | ||
- | 17390 ? Ssl 0:04 / | + | 44045 ? Ssl 0:03 / |
</ | </ | ||
Line 444: | Line 451: | ||
- | ===== Cisco IOS-XE | + | ===== Cisco IOS-XE Hints ===== |
- | This section shows the basic configuration needed to get route origin validation up and running on a Cisco IOS-XE | + | This section shows the basic configuration needed to get route origin validation up and running on Cisco IOS-XE platforms. |
- | Most commentary is for IOS-XE 16.x and IOS-XR 7.5 onwards. Older versions will also likely work with the following examples, but their RPKI implementation is somewhat old and buggy. | + | Most commentary is for IOS-XE 16.x. Older versions will also likely work with the following examples, but their RPKI implementation is somewhat old and buggy. |
==== IOS-XE Configuration with Validator ==== | ==== IOS-XE Configuration with Validator ==== | ||
Line 470: | Line 477: | ||
show ip bgp rpki servers | show ip bgp rpki servers | ||
</ | </ | ||
+ | |||
+ | ==== Cisco IOS-XE Caveats ==== | ||
+ | |||
+ | Cisco IOS-XE has many defaults which are non-standard and will be potentially frustrating for operators: | ||
+ | * Cannot specify a source-interface for the router to validator connection | ||
+ | * Automatically activates route origin validation (can be turned off!) | ||
+ | * Automatically drops invalids (can be turned off!) | ||
+ | * Locally originated prefixes are always marked as valid (cannot be turned off!) - fixed in most recent IOS-XE 17.x releases | ||
+ | * Automatically prefers Valid path over Invalid/ | ||
+ | * If validator disappears, router validation database is flushed within a few minutes - fixed in most recent IOS-XE 16.6 releases | ||
+ | |||
+ | To turn off the checking of the RPKI validation database (**IOS-XE 15.5 onwards**): | ||
+ | < | ||
+ | router bgp <ASN> | ||
+ | | ||
+ | bgp bestpath prefix-validate disable | ||
+ | | ||
+ | bgp bestpath prefix-validate disable | ||
+ | </ | ||
+ | The ROAs are still listed in the RPKI table but the router will not use them. (This should be the default, as per RFC.) | ||
+ | |||
+ | To turn off the automatic dropping of invalids: | ||
+ | < | ||
+ | router bgp <ASN> | ||
+ | | ||
+ | bgp bestpath prefix-validate allow-invalid | ||
+ | | ||
+ | bgp bestpath prefix-validate allow-invalid | ||
+ | </ | ||
+ | A new set up of RPKI in a Cisco IOS-XE network should start with " | ||
+ | < | ||
+ | router bgp <ASN> | ||
+ | | ||
+ | bgp bestpath prefix-validate disable | ||
+ | bgp bestpath prefix-validate allow-invalid | ||
+ | | ||
+ | bgp bestpath prefix-validate disable | ||
+ | bgp bestpath prefix-validate allow-invalid | ||
+ | </ | ||
+ | |||
+ | Once they are ready to implement RPKI, first remove the '' | ||
+ | |||
+ | The major show-stopper for an IOS-XE based network is the insertion of validation check in the BGP path selection process, over-riding '' | ||
+ | |||
+ | To propagate the validation state in IBGP, both BGP speakers need: | ||
+ | < | ||
+ | neighbor x.x.x.x announce rpki state | ||
+ | </ | ||
+ | Please do **NOT** do this, as there are operational consequences, | ||
+ | |||
+ | **Summary: | ||
+ | |||
+ | ===== Cisco IOS-XR Hints ===== | ||
+ | |||
+ | This section shows the basic configuration needed to get route origin validation up and running on Cisco IOS-XR platforms. | ||
+ | |||
+ | Most commentary is for IOS-XR 7.5 onwards. Older versions will also likely work with the following examples, but their RPKI implementation is likely to be more buggy. | ||
==== IOS-XR Configuration with Validator ==== | ==== IOS-XR Configuration with Validator ==== | ||
Line 529: | Line 593: | ||
</ | </ | ||
The sub-options will display all the prefixes fitting into each category. | The sub-options will display all the prefixes fitting into each category. | ||
- | |||
- | ==== Cisco IOS-XE Caveats ==== | ||
- | |||
- | Cisco IOS-XE has many defaults which are non-standard and will be potentially frustrating for operators: | ||
- | * Cannot specify a source-interface for the router to validator connection | ||
- | * Automatically activates route origin validation (can be turned off!) | ||
- | * Automatically drops invalids (can be turned off!) | ||
- | * Locally originated prefixes are always marked as valid (cannot be turned off!) - fixed in most recent IOS-XE 17.x releases | ||
- | * Automatically prefers Valid path over Invalid/ | ||
- | * If validator disappears, router validation database is flushed within a few minutes - fixed in most recent IOS-XE 16.6 releases | ||
- | |||
- | To turn off the checking of the RPKI validation database (**IOS-XE 15.5 onwards**): | ||
- | < | ||
- | router bgp <ASN> | ||
- | | ||
- | bgp bestpath prefix-validate disable | ||
- | | ||
- | bgp bestpath prefix-validate disable | ||
- | </ | ||
- | The ROAs are still listed in the RPKI table but the router will not use them. (This should be the default, as per RFC.) | ||
- | |||
- | To turn off the automatic dropping of invalids: | ||
- | < | ||
- | router bgp <ASN> | ||
- | | ||
- | bgp bestpath prefix-validate allow-invalid | ||
- | | ||
- | bgp bestpath prefix-validate allow-invalid | ||
- | </ | ||
- | A new set up of RPKI in a Cisco IOS-XE network should start with " | ||
- | < | ||
- | router bgp <ASN> | ||
- | | ||
- | bgp bestpath prefix-validate disable | ||
- | bgp bestpath prefix-validate allow-invalid | ||
- | | ||
- | bgp bestpath prefix-validate disable | ||
- | bgp bestpath prefix-validate allow-invalid | ||
- | </ | ||
- | |||
- | Once they are ready to implement RPKI, first remove the '' | ||
- | |||
- | The major show-stopper for an IOS-XE based network is the insertion of validation check in the BGP path selection process, over-riding '' | ||
- | |||
- | To propagate the validation state in IBGP, both BGP speakers need: | ||
- | < | ||
- | neighbor x.x.x.x announce rpki state | ||
- | </ | ||
- | Please do **NOT** do this, as there are operational consequences, | ||
- | |||
- | **Summary: | ||
- | |||
===== Juniper Hints ===== | ===== Juniper Hints ===== |
hints/rpki.1722404549.txt.gz · Last modified: by philip