Skip to main content

SecretString

Type Alias SecretString 

Source
pub type SecretString = Secret<String>;
Expand description

Secret string type — mirrors secrecy::SecretString (v0.8).

Type alias for Secret<String>. Implements FromStr, Clone (via String: CloneableSecret), and Debug (via String: DebugSecret).

Note: secrecy 0.10’s SecretString is SecretBox<str> (different type). Use v10::SecretString when migrating to v0.10 semantics.

Aliased Type§

pub struct SecretString { /* private fields */ }

Trait Implementations§

Source§

impl FromStr for SecretString

Source§

type Err = Infallible

The associated error which can be returned from parsing.
Source§

fn from_str(src: &str) -> Result<Self, Self::Err>

Parses a string s to return a value of this type. Read more