Enum shadowsocks_crypto::v1::CipherKind[][src]

pub enum CipherKind {
    NONE,
    AES_128_GCM,
    AES_256_GCM,
    CHACHA20_POLY1305,
}

ShadowSocks cipher type

Variants

NONE
AES_128_GCM

AEAD_AES_128_GCM

AES_256_GCM

AEAD_AES_256_GCM

CHACHA20_POLY1305

AEAD_CHACHA20_POLY1305

Implementations

impl CipherKind[src]

pub fn category(&self) -> CipherCategory[src]

The category of the cipher

pub fn is_none(&self) -> bool[src]

Check if the current cipher is NONE

pub fn is_aead(&self) -> bool[src]

Check if the current cipher is an AEAD cipher

pub fn key_len(&self) -> usize[src]

Key length of the cipher

pub fn tag_len(&self) -> usize[src]

AEAD Cipher’s TAG length

pub fn salt_len(&self) -> usize[src]

AEAD Cipher’s SALT length

Trait Implementations

impl Clone for CipherKind[src]

impl Copy for CipherKind[src]

impl Debug for CipherKind[src]

impl Display for CipherKind[src]

impl Eq for CipherKind[src]

impl FromStr for CipherKind[src]

type Err = ParseCipherKindError

The associated error which can be returned from parsing.

impl PartialEq<CipherKind> for CipherKind[src]

impl StructuralEq for CipherKind[src]

impl StructuralPartialEq for CipherKind[src]

Auto Trait Implementations

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T> ToString for T where
    T: Display + ?Sized
[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

impl<V, T> VZip<V> for T where
    V: MultiLane<T>,