Alexander Afanasyev | 151a855 | 2014-04-11 00:54:43 -0700 | [diff] [blame] | 1 | ndnsec-import |
| 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 | 102f057 | 2024-06-22 15:00:06 -0400 | [diff] [blame] | 7 | **ndnsec import** [**-h**] [**-P** *passphrase*] *file* |
Alexander Afanasyev | 151a855 | 2014-04-11 00:54:43 -0700 | [diff] [blame] | 8 | |
| 9 | Description |
| 10 | ----------- |
| 11 | |
Davide Pesavento | 102f057 | 2024-06-22 15:00:06 -0400 | [diff] [blame] | 12 | Import a certificate and its private key from a file in **SafeBag** format. |
| 13 | The command will interactively ask for a passphrase to be used for decrypting the private key. |
| 14 | If *file* is "-", the **SafeBag** data will be read from the standard input. |
Davide Pesavento | b310efb | 2019-04-11 22:10:24 -0400 | [diff] [blame] | 15 | |
Davide Pesavento | 102f057 | 2024-06-22 15:00:06 -0400 | [diff] [blame] | 16 | :program:`ndnsec-export` can be used to create a file in the expected format. |
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:: -P <passphrase>, --password <passphrase> |
Junxiao Shi | 476200b | 2017-10-05 12:16:27 +0000 | [diff] [blame] | 22 | |
Davide Pesavento | 102f057 | 2024-06-22 15:00:06 -0400 | [diff] [blame] | 23 | Passphrase to use for decryption. If empty or not specified, the user is |
Davide Pesavento | b310efb | 2019-04-11 22:10:24 -0400 | [diff] [blame] | 24 | interactively asked to type the passphrase on the terminal. Note that |
| 25 | specifying the passphrase via this option is insecure, as it can potentially |
| 26 | end up in the shell's history, be visible in :command:`ps` output, and so on. |
Alexander Afanasyev | 634a62b | 2018-06-15 16:55:26 -0400 | [diff] [blame] | 27 | |
Davide Pesavento | 102f057 | 2024-06-22 15:00:06 -0400 | [diff] [blame] | 28 | Examples |
| 29 | -------- |
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 | Import a certificate and private key from a file:: |
Alexander Afanasyev | 151a855 | 2014-04-11 00:54:43 -0700 | [diff] [blame] | 32 | |
Davide Pesavento | 102f057 | 2024-06-22 15:00:06 -0400 | [diff] [blame] | 33 | $ ndnsec import alice.ndnkey |
| 34 | |
| 35 | See Also |
| 36 | -------- |
| 37 | |
| 38 | :manpage:`ndnsec-cert-install(1)`, |
| 39 | :manpage:`ndnsec-export(1)` |