Alexander Afanasyev | 151a855 | 2014-04-11 00:54:43 -0700 | [diff] [blame] | 1 | ndnsec-cert-dump |
| 2 | ================ |
| 3 | |
Davide Pesavento | b310efb | 2019-04-11 22:10:24 -0400 | [diff] [blame] | 4 | Synopsis |
| 5 | -------- |
Alexander Afanasyev | 151a855 | 2014-04-11 00:54:43 -0700 | [diff] [blame] | 6 | |
Davide Pesavento | b310efb | 2019-04-11 22:10:24 -0400 | [diff] [blame] | 7 | **ndnsec-cert-dump** [**-h**] [**-p**] [**-r** [**-H** *host*] [**-P** *port*]] |
| 8 | [**-i**\|\ **-k**\|\ **-f**] *name* |
Alexander Afanasyev | 151a855 | 2014-04-11 00:54:43 -0700 | [diff] [blame] | 9 | |
| 10 | Description |
| 11 | ----------- |
| 12 | |
Davide Pesavento | b310efb | 2019-04-11 22:10:24 -0400 | [diff] [blame] | 13 | :program:`ndnsec-cert-dump` reads a certificate from the **Public Info Base (PIB)** |
Davide Pesavento | dd0724b | 2022-04-18 00:30:05 -0400 | [diff] [blame] | 14 | or from a file, and prints it on the standard output in Base64 encoding. |
Alexander Afanasyev | 151a855 | 2014-04-11 00:54:43 -0700 | [diff] [blame] | 15 | |
Davide Pesavento | b310efb | 2019-04-11 22:10:24 -0400 | [diff] [blame] | 16 | By default, *name* is interpreted as a certificate name. |
Alexander Afanasyev | 151a855 | 2014-04-11 00:54:43 -0700 | [diff] [blame] | 17 | |
| 18 | Options |
| 19 | ------- |
| 20 | |
Davide Pesavento | b310efb | 2019-04-11 22:10:24 -0400 | [diff] [blame] | 21 | .. option:: -i, --identity |
Alexander Afanasyev | 151a855 | 2014-04-11 00:54:43 -0700 | [diff] [blame] | 22 | |
Davide Pesavento | b310efb | 2019-04-11 22:10:24 -0400 | [diff] [blame] | 23 | Interpret *name* as an identity name. If specified, the certificate to dump |
| 24 | is the default certificate of the identity. |
Alexander Afanasyev | 151a855 | 2014-04-11 00:54:43 -0700 | [diff] [blame] | 25 | |
Davide Pesavento | b310efb | 2019-04-11 22:10:24 -0400 | [diff] [blame] | 26 | .. option:: -k, --key |
Alexander Afanasyev | 151a855 | 2014-04-11 00:54:43 -0700 | [diff] [blame] | 27 | |
Davide Pesavento | b310efb | 2019-04-11 22:10:24 -0400 | [diff] [blame] | 28 | Interpret *name* as a key name. If specified, the certificate to dump is the |
| 29 | default certificate of the key. |
Alexander Afanasyev | 151a855 | 2014-04-11 00:54:43 -0700 | [diff] [blame] | 30 | |
Davide Pesavento | b310efb | 2019-04-11 22:10:24 -0400 | [diff] [blame] | 31 | .. option:: -f, --file |
Alexander Afanasyev | 151a855 | 2014-04-11 00:54:43 -0700 | [diff] [blame] | 32 | |
Davide Pesavento | b310efb | 2019-04-11 22:10:24 -0400 | [diff] [blame] | 33 | Interpret *name* as a path to a file containing the certificate. If *name* |
| 34 | is "-", the certificate will be read from the standard input. |
| 35 | |
| 36 | .. option:: -p, --pretty |
| 37 | |
| 38 | Print the certificate in a human-readable format. |
| 39 | |
| 40 | Example |
| 41 | ------- |
| 42 | |
| 43 | Dump a certificate from PIB to standard output:: |
Alexander Afanasyev | 151a855 | 2014-04-11 00:54:43 -0700 | [diff] [blame] | 44 | |
Alexander Afanasyev | 35109a1 | 2017-01-04 15:39:06 -0800 | [diff] [blame] | 45 | $ ndnsec-cert-dump /ndn/test/david/KEY/ksk-1396913058196/ID-CERT/%00%00%01E%3E%9D%A0%DE |
Alexander Afanasyev | 151a855 | 2014-04-11 00:54:43 -0700 | [diff] [blame] | 46 | |
Davide Pesavento | dd0724b | 2022-04-18 00:30:05 -0400 | [diff] [blame] | 47 | Print the NDN testbed root certificate in human-readable format:: |
Alexander Afanasyev | 151a855 | 2014-04-11 00:54:43 -0700 | [diff] [blame] | 48 | |
Davide Pesavento | dd0724b | 2022-04-18 00:30:05 -0400 | [diff] [blame] | 49 | $ curl -A ndnsec -fsLS https://named-data.net/ndnsec/ndn-testbed-root.ndncert.x3.base64 | ndnsec-cert-dump -fp - |
| 50 | Certificate Name: |
| 51 | /ndn/KEY/%EC%F1L%8EQ%23%15%E0/ndn/%FD%00%00%01u%E6%7F2%10 |
| 52 | Additional Description: |
| 53 | fullname: NDN Testbed Root X3 |
| 54 | Public Key: |
| 55 | Key Type: 256-bit EC |
| 56 | MFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAEGx+3Y4FvYo1eScIvgD74lQhQdzN4 |
| 57 | zq021dop8t7kGfEpfGdKf2HGpnn4/qoF9iJ1yUZE/7Na8zzO4xT6RpIM0Q== |
Alexander Afanasyev | 151a855 | 2014-04-11 00:54:43 -0700 | [diff] [blame] | 58 | Validity: |
Davide Pesavento | dd0724b | 2022-04-18 00:30:05 -0400 | [diff] [blame] | 59 | Not Before: 2020-11-20T16:31:37 |
| 60 | Not After: 2024-12-31T23:59:59 |
| 61 | Signature Information: |
| 62 | Signature Type: SignatureSha256WithEcdsa |
| 63 | Key Locator: Name=/ndn/KEY/%EC%F1L%8EQ%23%15%E0 |
| 64 | Self-Signed: yes |