ND...ONF(5)

πŸ“¦
version 0.9.0 Β· 2 versions
, in nixos 26.05

πŸ’… NDN CLIENT CONFIG 😀✨

okay bestie, gather 'round because this is the manual for ndn-client.conf β€” yes that's the config file situation for NDN applications, and it's genuinely important so pay attention πŸ’–


✨ NAME ✨

ndn-client.conf β€” the literal main character config file for NDN applications, no cap πŸŽ€


🌸 DESCRIPTION 🌸

so like, the System configuration of the NDN platform? it lives in client.conf. that's the whole vibe.

when an application is like "where's my config bestie" the file client.conf gets looked up in several directories, and the order MATTERS:

  • $HOME/.ndn β€” user-specific settings, this is your personal little corner πŸ’–
  • SYSCONFDIR/ndn β€” system-wide settings (and just so you know, SYSCONFDIR can be /usr/local/etc, /opt/local/etc, or whatever else, it literally depends on how the library is configured, iykyk)
  • /etc/ndn β€” default system-wide settings, the fallback queen πŸ‘‘

and here's an example of client.conf for the current ndn-cxx package, live and direct, don't skip the comments they're lowkey everything:

; "transport" specifies the default transport connection used by the client-side face to communicate
; with a (local or remote) NDN forwarder. The value must be a Face URI with a Unix or TCP scheme.
;
; For example:
;   unix:///tmp/nfd/nfd.sock
;   tcp://192.0.2.1
;   tcp4://example.com:6363
;   tcp6://[2001:db8::1]:6363
;
; The default value of this field is platform-dependent, being "unix:///run/nfd/nfd.sock" on Linux
; and "unix:///var/run/nfd/nfd.sock" on other platforms.
;
;transport=unix:///var/run/nfd/nfd.sock

; "pib" determines which Public Information Base (PIB) should used by default in applications.
; Currently, the only supported value for "pib" is:
;   - "pib-sqlite3"     (default if not specified)
;
;pib=pib-sqlite3

; "tpm" determines which Trusted Platform Module (TPM) should used by default in applications.
; The supported values for "tpm" are:
;   - "tpm-file"         (default if not specified)
;   - "tpm-osxkeychain"
;
;tpm=tpm-file

πŸ¦‹ FORWARDER πŸ¦‹

transport

so this one is the FaceUri for the default connection toward the local or remote NDN forwarder. that's it, that's the job πŸ’…

the only FaceUris accepted are unix, tcp, tcp4, and tcp6 β€” anything else? not invited to the party 🚫

by default, unix:///run/nfd/nfd.sock is used on Linux and unix:///var/run/nfd/nfd.sock is used on other platforms. love that for them 🌈

Note: this value can be overridden using the NDN_CLIENT_TRANSPORT environment variable. the env var said "i'm the captain now" fr fr

πŸ” KEY MANAGEMENT πŸ”

pib

this is the public key information for each private key stored in TPM. the format for this setting is literally:

pib=[scheme]:[location]

possible values for [scheme] are:

  • pib-sqlite3 β€” local PIB implementation using the SQLite3 storage engine. and yes, this is the default, she's the moment πŸ‘‘

possible values for [location]:

  • absolute path where the SQLite3 database will be stored
  • relative path (relative to client.conf)
  • empty: the default path $HOME/.ndn will be used

when [location] is empty, the trailing : can be omitted. for example:

pib=pib-sqlite3

changing PIB scheme without changing location is not allowed. like, not allowed allowed. if a change like this is necessary, the whole backend storage must be destroyed. for example, when the default location is used:

rm -rf ~/.ndn/ndnsec-*
⚠️ it is not recommended to share the same directory between machines, e.g. via NFS. simultaneous access from multiple machines may cause errors. like please don't do this, it's giving chaos πŸ˜­πŸ’€
Note: this value can be overridden using the NDN_CLIENT_PIB environment variable. env var stays winning

tpm

this is the Trusted Platform Module (TPM) where the private keys are stored. the format for this setting is:

tpm=[scheme]:[location]

possible values for [scheme] are:

  • tpm-osxkeychain β€” secure storage of private keys in the macOS Keychain with OS-provided access restrictions. iconic behavior honestly πŸ“

the [location] parameter is ignored. she doesn't need it.

may not work for daemon applications, as user interaction may be required to access the macOS Keychain. so like, just a heads up πŸ™ˆ

  • tpm-file β€” file-based storage of private keys. and this is the default, periodt πŸ’…

possible values for [location]:

  • absolute path to directory that will store private/public key files (unencrypted with 0700 permission)
  • relative path (relative to client.conf)
  • empty: the default path $HOME/.ndn/ndnsec-key-file will be used

when [location] is empty, the trailing : can be omitted. for example:

tpm=tpm-file

changing the tpm setting is only possible together with pib setting. otherwise, an error will be generated during PIB/TPM access. they're a package deal bestie, it's giving ride or die 🀝

⚠️ it is not recommended to share the same directory between machines, e.g. via NFS. simultaneous access from multiple machines may cause errors. same warning as before, still true, still important 🚨
Note: this value can be overridden using the NDN_CLIENT_TPM environment variable. the env vars are literally running this whole operation ngl

Copyright Β© 2013-2024 Regents of the University of California.


and that's the whole thing bestie! this page is from version 0.9.0 dated 1980-01-01 β€” iconic vintage energy, the way that date is literally older than the concept of vibes but here we are πŸ§šβ€β™€οΈβœ¨ stay configured, stay slaying πŸ’œ

πŸ“¦ where this page comes from