Expand description
FIPS Configuration System
Loads configuration from YAML files with a cascading priority system:
./fips.yaml(current directory - highest priority)~/.config/fips/fips.yaml(user config directory)/etc/fips/fips.yaml(system - lowest priority)
Values from higher priority files override those from lower priority files.
§YAML Structure
The YAML structure mirrors the sysctl-style paths in the architecture docs.
For example, node.identity.nsec in the docs corresponds to:
node:
identity:
nsec: "nsec1..."Structs§
- BleConfig
- BLE transport instance configuration.
- Bloom
Config - Bloom filter (
node.bloom.*). - Buffers
Config - Internal buffers (
node.buffers.*). - Cache
Config - Cache parameters (
node.cache.*). - Config
- Root configuration structure.
- Conntrack
Config - Conntrack timeout overrides (
gateway.conntrack.*). - Control
Config - Control socket configuration (
node.control.*). - Directory
Service Config - Directory-mode onion service configuration.
- Discovery
Config - Discovery protocol (
node.discovery.*). - Ethernet
Config - Ethernet transport instance configuration.
- Gateway
Config - Gateway configuration (
gateway.*). - Gateway
DnsConfig - Gateway DNS resolver configuration (
gateway.dns.*). - Identity
Config - Identity configuration (
node.identity.*). - Limits
Config - Resource limits (
node.limits.*). - Node
Config - Node configuration (
node.*). - Nostr
Discovery Config - Nostr-mediated overlay endpoint discovery (
node.discovery.nostr.*). - Peer
Address - A transport-specific address for reaching a peer.
- Peer
Config - Configuration for a known peer.
- Port
Forward - An inbound port-forward rule:
fips0:listen_port/proto→target. - Rate
Limit Config - Rate limiting (
node.rate_limit.*). - Rekey
Config - Resolved
Identity - Result of identity resolution.
- Retry
Config - Retry/backoff configuration (
node.retry.*). - Routing
Config - Routing strategy selection (
node.routing.*). - Session
Config - Session/data plane (
node.session.*). - Session
MmpConfig - Session-layer Metrics Measurement Protocol (
node.session_mmp.*). - TcpConfig
- TCP transport instance configuration.
- TorConfig
- Tor transport instance configuration.
- Transports
Config - Transports configuration section.
- Tree
Config - Spanning tree (
node.tree.*). - UdpConfig
- UDP transport instance configuration.
Enums§
- Config
Error - Errors that can occur during configuration loading.
- Connect
Policy - Connection policy for a peer.
- Identity
Source - Where a resolved identity originated.
- Nostr
Discovery Policy - Nostr advert discovery policy.
- Proto
- Transport protocol for an inbound port forward.
- Routing
Mode - Daemon routing mode.
- Transport
Instances - Transport instances - either a single config or named instances.
Functions§
- default_
control_ path - Default control socket path for fipsctl / fipstop.
- default_
gateway_ path - Default gateway control socket path.
- key_
file_ path - Derive the key file path from a config file path.
- pub_
file_ path - Derive the public key file path from a config file path.
- read_
key_ file - Read a bare bech32 nsec from a key file.
- resolve_
identity - Resolve identity from config and key file.
- write_
key_ file - Write a bare bech32 nsec to a key file with restricted permissions.
- write_
pub_ file - Write a bare bech32 npub to a public key file.