pub enum AuthType {
Auth,
PrivateKey,
HttpProxy,
SocksProxy,
Custom(String),
}Expand description
Authentication credential type. OpenVPN identifies credential requests
by a quoted type string — usually "Auth" or "Private Key", but
plugins can define custom types.
Variants§
Auth
Standard --auth-user-pass credentials. Wire: "Auth".
PrivateKey
Private key passphrase (encrypted key file). Wire: "Private Key".
HttpProxy
HTTP proxy credentials. Wire: "HTTP Proxy".
SocksProxy
SOCKS proxy credentials. Wire: "SOCKS Proxy".
Custom(String)
Plugin-defined or otherwise unrecognized auth type.
Trait Implementations§
Source§impl FromStr for AuthType
impl FromStr for AuthType
Source§fn from_str(s: &str) -> Result<Self, Self::Err>
fn from_str(s: &str) -> Result<Self, Self::Err>
Parse an auth type string. Recognized values: Auth, PrivateKey /
Private Key, HTTPProxy / HTTP Proxy, SOCKSProxy / SOCKS Proxy.
Anything else becomes AuthType::Custom.
Source§type Err = Infallible
type Err = Infallible
The associated error which can be returned from parsing.
impl Eq for AuthType
impl StructuralPartialEq for AuthType
Auto Trait Implementations§
impl Freeze for AuthType
impl RefUnwindSafe for AuthType
impl Send for AuthType
impl Sync for AuthType
impl Unpin for AuthType
impl UnsafeUnpin for AuthType
impl UnwindSafe for AuthType
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