pub struct FipsEndpointBuilder { /* private fields */ }Expand description
Builder for an embedded FIPS endpoint.
Implementations§
Source§impl FipsEndpointBuilder
impl FipsEndpointBuilder
Sourcepub fn config(self, config: Config) -> FipsEndpointBuilder
pub fn config(self, config: Config) -> FipsEndpointBuilder
Start from an explicit FIPS config.
Sourcepub fn identity_nsec(self, nsec: impl Into<String>) -> FipsEndpointBuilder
pub fn identity_nsec(self, nsec: impl Into<String>) -> FipsEndpointBuilder
Use an nsec or hex secret for the endpoint identity.
Sourcepub fn discovery_scope(self, scope: impl Into<String>) -> FipsEndpointBuilder
pub fn discovery_scope(self, scope: impl Into<String>) -> FipsEndpointBuilder
Set an application-level discovery scope.
When the builder owns the default empty connectivity config, this also enables scoped Nostr discovery, open same-scope peer discovery, local LAN candidates, and a UDP NAT advert. If an explicit transport or Nostr config was supplied, the explicit config is left in control and the scope is retained as endpoint metadata.
Sourcepub fn local_ethernet(self, interface: impl Into<String>) -> FipsEndpointBuilder
pub fn local_ethernet(self, interface: impl Into<String>) -> FipsEndpointBuilder
Enable host-local Ethernet discovery on a private L2 interface.
This is intended for veth/TAP interfaces attached to a per-host bridge shared by FIPS-aware applications. The endpoint announces Ethernet beacons, listens for matching peers, auto-connects to them, and accepts inbound handshakes over the interface.
Sourcepub fn without_system_tun(self) -> FipsEndpointBuilder
pub fn without_system_tun(self) -> FipsEndpointBuilder
Disable FIPS-owned TUN and DNS system integration.
Sourcepub fn packet_channel_capacity(self, capacity: usize) -> FipsEndpointBuilder
pub fn packet_channel_capacity(self, capacity: usize) -> FipsEndpointBuilder
Set the app packet/data channel capacity.
Sourcepub async fn bind(self) -> Result<FipsEndpoint, FipsEndpointError>
pub async fn bind(self) -> Result<FipsEndpoint, FipsEndpointError>
Bind and start the embedded endpoint.
Trait Implementations§
Source§impl Clone for FipsEndpointBuilder
impl Clone for FipsEndpointBuilder
Source§fn clone(&self) -> FipsEndpointBuilder
fn clone(&self) -> FipsEndpointBuilder
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 FipsEndpointBuilder
impl Debug for FipsEndpointBuilder
Source§impl Default for FipsEndpointBuilder
impl Default for FipsEndpointBuilder
Source§fn default() -> FipsEndpointBuilder
fn default() -> FipsEndpointBuilder
Auto Trait Implementations§
impl Freeze for FipsEndpointBuilder
impl RefUnwindSafe for FipsEndpointBuilder
impl Send for FipsEndpointBuilder
impl Sync for FipsEndpointBuilder
impl Unpin for FipsEndpointBuilder
impl UnsafeUnpin for FipsEndpointBuilder
impl UnwindSafe for FipsEndpointBuilder
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
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