pub struct SecurityConfig {
pub key_file: PathBuf,
pub require_encryption: bool,
pub authorization_policy: AuthorizationPolicy,
pub authorized_peers: Vec<NodeId>,
pub trust_store_file: PathBuf,
}Expand description
Encryption policy and key storage configuration.
Fields§
§key_file: PathBufPath to the Ed25519 private key file for this node.
require_encryption: boolWhether unencrypted sessions should be rejected.
Authorization policy applied after peer identity is authenticated.
Explicitly authorized peers when authorization_policy = "allow_list".
trust_store_file: PathBufPersistent trust store used by trust_on_first_use.
Trait Implementations§
Source§impl Clone for SecurityConfig
impl Clone for SecurityConfig
Source§fn clone(&self) -> SecurityConfig
fn clone(&self) -> SecurityConfig
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for SecurityConfig
impl Debug for SecurityConfig
Source§impl Default for SecurityConfig
impl Default for SecurityConfig
Source§impl<'de> Deserialize<'de> for SecurityConfig
impl<'de> Deserialize<'de> for SecurityConfig
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>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl PartialEq for SecurityConfig
impl PartialEq for SecurityConfig
Source§fn eq(&self, other: &SecurityConfig) -> bool
fn eq(&self, other: &SecurityConfig) -> bool
Tests for
self and other values to be equal, and is used by ==.Source§impl Serialize for SecurityConfig
impl Serialize for SecurityConfig
impl StructuralPartialEq for SecurityConfig
Auto Trait Implementations§
impl Freeze for SecurityConfig
impl RefUnwindSafe for SecurityConfig
impl Send for SecurityConfig
impl Sync for SecurityConfig
impl Unpin for SecurityConfig
impl UnsafeUnpin for SecurityConfig
impl UnwindSafe for SecurityConfig
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
Mutably borrows from an owned value. Read more