pub struct ServerConfig {Show 21 fields
pub mode: ServerMode,
pub bind_address: String,
pub enable_auth: bool,
pub enable_fips: bool,
pub fips_discovery_scope: String,
pub fips_open_discovery_max_pending: usize,
pub fips_local_rendezvous_addr: Option<String>,
pub enable_fips_lan_discovery: bool,
pub fips_relays: Option<Vec<String>>,
pub fips_peers: Vec<ConfiguredFipsPeer>,
pub enable_fips_udp: bool,
pub fips_udp_bind_addr: Option<String>,
pub fips_udp_public: bool,
pub fips_udp_external_addr: Option<String>,
pub enable_fips_webrtc: bool,
pub fips_ethernet_interfaces: Vec<String>,
pub fetch_from_fips_peers: bool,
pub fips_request_timeout_ms: u64,
pub public_writes: bool,
pub public_plaintext_reads: bool,
pub socialgraph_snapshot_public: bool,
}Fields§
§mode: ServerMode§bind_address: String§enable_auth: bool§enable_fips: boolEnable FIPS-backed Hashtree blob exchange.
fips_discovery_scope: StringFIPS discovery/signaling scope for Hashtree peers.
fips_open_discovery_max_pending: usizeMaximum unconfigured peers allowed to enter Nostr discovery concurrently. Zero keeps discovery restricted to configured/social-graph peers.
fips_local_rendezvous_addr: Option<String>Optional loopback rendezvous address override for isolated local stacks. Unset uses the FIPS well-known address (127.0.0.1:21211).
enable_fips_lan_discovery: boolEnable FIPS LAN/mDNS peer discovery.
fips_relays: Option<Vec<String>>FIPS Nostr relays used for discovery adverts and encrypted signaling. Unset uses active nostr.relays plus FIPS defaults; an explicit empty list disables relay discovery.
fips_peers: Vec<ConfiguredFipsPeer>Always-configured Hashtree FIPS peers. These are useful for origin/cache pairs that should connect immediately without waiting for discovery.
enable_fips_udp: boolEnable ordinary FIPS UDP endpoint transport.
fips_udp_bind_addr: Option<String>FIPS UDP bind address. Empty/default lets the kernel pick an ephemeral port.
fips_udp_public: boolAdvertise the FIPS UDP endpoint as directly reachable.
fips_udp_external_addr: Option<String>Explicit FIPS UDP address to advertise when fips_udp_public is true.
enable_fips_webrtc: boolEnable FIPS WebRTC endpoint transport.
fips_ethernet_interfaces: Vec<String>Host-local Ethernet interfaces for FIPS endpoint transport.
fetch_from_fips_peers: boolAllow daemon cache misses to fetch blobs from FIPS peers.
fips_request_timeout_ms: u64How long one FIPS blob request waits for a valid response.
public_writes: boolAllow anyone with valid Nostr auth to write (default: true) When false, only social graph members can write
public_plaintext_reads: boolAllow public plaintext reads from mutable npub routes (default: true) When false, only configured or social graph approved npubs are served.
Allow public access to social graph snapshot endpoint (default: false)
Implementations§
Source§impl ServerConfig
impl ServerConfig
pub fn resolved_fips_relays( &self, active_nostr_relays: &[String], ) -> Vec<String>
Trait Implementations§
Source§impl Clone for ServerConfig
impl Clone for ServerConfig
Source§fn clone(&self) -> ServerConfig
fn clone(&self) -> ServerConfig
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for ServerConfig
impl Debug for ServerConfig
Source§impl Default for ServerConfig
impl Default for ServerConfig
Source§impl<'de> Deserialize<'de> for ServerConfig
impl<'de> Deserialize<'de> for ServerConfig
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Auto Trait Implementations§
impl Freeze for ServerConfig
impl RefUnwindSafe for ServerConfig
impl Send for ServerConfig
impl Sync for ServerConfig
impl Unpin for ServerConfig
impl UnsafeUnpin for ServerConfig
impl UnwindSafe for ServerConfig
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more