rtrclient(1) General Commands Manual rtrclient(1)

# [NAME](#NAME)

rtrclient - rtr rpki client

# [SYNOPSIS](#SYNOPSIS)

**rtrclient** \[**-kph**] *SOCKETS...*

# [SOCKETS](#SOCKETS)

**tcp** \[**-kpb bindaddr**] *HOST* *PORT*  
**ssh** \[**-kpb bindaddr**] *HOST* *PORT* *USERNAME* (*PRIVATE\_KEY*|*PASSWORD*) \[*HOST\_KEY*]

# [DESCRIPTION](#DESCRIPTION)

**rtrclient** connects to an RPKI/RTR cache server and prints prefix, origin AS, and router key updates. **rtrclient** can use plain tcp or ssh transport to connect to an RPKI/RTR cache server. The amount is not limited and different transport types can be mixed arbitrarily.

For **tcp** you must specify the *HOST* and *PORT*.

For **ssh** you must specify the *HOST*, *PORT*, *USERNAME* and a file containing the *PRIVATE\_KEY* or a *PASSWORD*. By default the rtrclient will try to guess which of the two was entered. If you want to explicitly specify this see **-w** and **-s**. You may specify a file containing a list of *HOST\_KEY*s, in the well known **SSH\_KNOWN\_HOSTS** file format. See [*sshd(8)*](/man/os/rtrlib/sshd.8) for details.

# [OPTIONS](#OPTIONS)

**-b bindaddr**

Set explicit bind address

**-h**

Print help message

**-k**

Print information about router key updates

**-p**

Print information about prefix and origin AS updates

**-s**

Print information about connection status updates

**-e**

Export ROAs after completing synchronisation and exit

**-t**

Select template for pfx export. May be a build in template (see **-l**) or a file path to a custom template (see **TEMPLATES**)

**-l**

Print available templates and exit. Prints specified templated, when used with -t.

**-o**

Output file for export

**-w**

force ssh authentication information to be interpreted as a password

**-s**

force ssh authentication information to be interpreted as a private key

# [TEMPLATES](#TEMPLATES)

Templates can be used to export ROA information in a custom format. They are written in the **mustache**(*https://mustache.github.io/*) templating language.

A template should contain a section called **roas** which may contain the variables **prefix**, **length**, **maxlen** and **origin**. The content of this section is expanded for every entry in the ROA table. The special variable **last** is true for the last entry of the prefix table. See the json template for a usage example.

# [EXAMPLES](#EXAMPLES)

Print prefix and origin AS updates from a tcp based server

```
rtrclient tcp -k rpki.example.com 323
```

```

```

Print prefix and router key updates from a ssh based server

```
rtrclient ssh -k -p rpki.example.com 22 rtr-ssh ~/.ssh/id_rsa ~/.ssh/known_hosts
```

```

```

Use multiple rtr server, print prefix updates for some

```
rtrclient tcp -p rpki.example.com 323 tcp rpki2.example.com 323 ssh -p rpki.example.com 22 rtr-ssh ~/.ssh/id_rsa
```

---

Document: rtrclient(1) from rtrlib 0.8.0-r6 (Chainguard OS)
Source: https://github.com/rtrlib/rtrlib
