Decoder

Struct Decoder 

Source
pub struct Decoder<Type> {
    pub name: &'static str,
    pub description: &'static str,
    pub link: &'static str,
    pub tags: Vec<&'static str>,
    pub popularity: f32,
    pub phantom: PhantomData<Type>,
}
Expand description

! The Interface defines what the struct for each decoder looks like

Fields§

§name: &'static str

The English name of the decoder.

§description: &'static str

A description, you can take the first line from Wikipedia Sometimes our decoders do not exist on Wikipedia so we write our own.

§link: &'static str

Wikipedia Link

§tags: Vec<&'static str>

The tags it has. See other decoders. Think of it as a “category” This is used to filter decoders. For example, if you want to filter decoders that are “base64” you would use the tag “base64” or “base”. You can also add tags like “online” to filter decoders that are online.

§popularity: f32

We get popularity by eye-balling it or using the API’s data

§phantom: PhantomData<Type>

we don’t use the Type, so we use PhantomData to mark it!

Trait Implementations§

Source§

impl Crack for Decoder<AtbashDecoder>

Source§

fn crack(&self, text: &str, checker: &CheckerTypes) -> CrackResult

This function does the actual decoding It returns an Option if it was successful Else the Option returns nothing and the error is logged in Trace

Source§

fn get_tags(&self) -> &Vec<&str>

Gets all tags for this decoder

Source§

fn get_name(&self) -> &str

Gets the name for the current decoder

Source§

fn new() -> Decoder<AtbashDecoder>

This function generates a new crack trait
Source§

impl Crack for Decoder<Base32Decoder>

Source§

fn crack(&self, text: &str, checker: &CheckerTypes) -> CrackResult

This function does the actual decoding It returns an Option if it was successful Else the Option returns nothing and the error is logged in Trace

Source§

fn get_tags(&self) -> &Vec<&str>

Gets all tags for this decoder

Source§

fn get_name(&self) -> &str

Gets the name for the current decoder

Source§

fn new() -> Decoder<Base32Decoder>

This function generates a new crack trait
Source§

impl Crack for Decoder<Base58BitcoinDecoder>

Source§

fn crack(&self, text: &str, checker: &CheckerTypes) -> CrackResult

This function does the actual decoding It returns an Option if it was successful Else the Option returns nothing and the error is logged in Trace

Source§

fn get_tags(&self) -> &Vec<&str>

Gets all tags for this decoder

Source§

fn get_name(&self) -> &str

Gets the name for the current decoder

Source§

fn new() -> Decoder<Base58BitcoinDecoder>

This function generates a new crack trait
Source§

impl Crack for Decoder<Base58FlickrDecoder>

Source§

fn crack(&self, text: &str, checker: &CheckerTypes) -> CrackResult

This function does the actual decoding It returns an Option if it was successful Else the Option returns nothing and the error is logged in Trace

Source§

fn get_tags(&self) -> &Vec<&str>

Gets all tags for this decoder

Source§

fn get_name(&self) -> &str

Gets the name for the current decoder

Source§

fn new() -> Decoder<Base58FlickrDecoder>

This function generates a new crack trait
Source§

impl Crack for Decoder<Base58MoneroDecoder>

Source§

fn crack(&self, text: &str, checker: &CheckerTypes) -> CrackResult

This function does the actual decoding It returns an Option if it was successful Else the Option returns nothing and the error is logged in Trace

Source§

fn get_tags(&self) -> &Vec<&str>

Gets all tags for this decoder

Source§

fn get_name(&self) -> &str

Gets the name for the current decoder

Source§

fn new() -> Decoder<Base58MoneroDecoder>

This function generates a new crack trait
Source§

impl Crack for Decoder<Base58RippleDecoder>

Source§

fn crack(&self, text: &str, checker: &CheckerTypes) -> CrackResult

This function does the actual decoding It returns an Option if it was successful Else the Option returns nothing and the error is logged in Trace

Source§

fn get_tags(&self) -> &Vec<&str>

Gets all tags for this decoder

Source§

fn get_name(&self) -> &str

Gets the name for the current decoder

Source§

fn new() -> Decoder<Base58RippleDecoder>

This function generates a new crack trait
Source§

impl Crack for Decoder<Base64Decoder>

Source§

fn crack(&self, text: &str, checker: &CheckerTypes) -> CrackResult

This function does the actual decoding It returns an Option if it was successful Else the Option returns nothing and the error is logged in Trace

Source§

fn get_tags(&self) -> &Vec<&str>

Gets all tags for this decoder

Source§

fn get_name(&self) -> &str

Gets the name for the current decoder

Source§

fn new() -> Decoder<Base64Decoder>

This function generates a new crack trait
Source§

impl Crack for Decoder<Base64URLDecoder>

Source§

fn crack(&self, text: &str, checker: &CheckerTypes) -> CrackResult

This function does the actual decoding It returns an Option if it was successful Else the Option returns nothing and the error is logged in Trace

Source§

fn get_tags(&self) -> &Vec<&str>

Gets all tags for this decoder

Source§

fn get_name(&self) -> &str

Gets the name for the current decoder

Source§

fn new() -> Decoder<Base64URLDecoder>

This function generates a new crack trait
Source§

impl Crack for Decoder<Base65536Decoder>

Source§

fn crack(&self, text: &str, checker: &CheckerTypes) -> CrackResult

This function does the actual decoding It returns an Option if it was successful Else the Option returns nothing and the error is logged in Trace

Source§

fn get_tags(&self) -> &Vec<&str>

Gets all tags for this decoder

Source§

fn get_name(&self) -> &str

Gets the name for the current decoder

Source§

fn new() -> Decoder<Base65536Decoder>

This function generates a new crack trait
Source§

impl Crack for Decoder<Base91Decoder>

Source§

fn crack(&self, text: &str, checker: &CheckerTypes) -> CrackResult

This function does the actual decoding It returns an Option if it was successful Else the Option returns nothing and the error is logged in Trace

Source§

fn get_tags(&self) -> &Vec<&str>

Gets all tags for this decoder

Source§

fn get_name(&self) -> &str

Gets the name for the current decoder

Source§

fn new() -> Decoder<Base91Decoder>

This function generates a new crack trait
Source§

impl Crack for Decoder<BinaryDecoder>

Source§

fn crack(&self, text: &str, checker: &CheckerTypes) -> CrackResult

This function does the actual decoding It returns an Option if it was successful Else the Option returns nothing and the error is logged in Trace

Source§

fn get_tags(&self) -> &Vec<&str>

Gets all tags for this decoder

Source§

fn get_name(&self) -> &str

Gets the name for the current decoder

Source§

fn new() -> Decoder<BinaryDecoder>

This function generates a new crack trait
Source§

impl Crack for Decoder<CaesarDecoder>

Source§

fn crack(&self, text: &str, checker: &CheckerTypes) -> CrackResult

This function does the actual decoding It returns an Option if it was successful Else the Option returns nothing and the error is logged in Trace

Source§

fn get_tags(&self) -> &Vec<&str>

Gets all tags for this decoder

Source§

fn get_name(&self) -> &str

Gets the name for the current decoder

Source§

fn new() -> Decoder<CaesarDecoder>

This function generates a new crack trait
Source§

impl Crack for Decoder<CitrixCTX1Decoder>

Source§

fn crack(&self, text: &str, checker: &CheckerTypes) -> CrackResult

This function does the actual decoding It returns an Option if it was successful Else the Option returns nothing and the error is logged in Trace

Source§

fn get_tags(&self) -> &Vec<&str>

Gets all tags for this decoder

Source§

fn get_name(&self) -> &str

Gets the name for the current decoder

Source§

fn new() -> Decoder<CitrixCTX1Decoder>

This function generates a new crack trait
Source§

impl Crack for Decoder<HexadecimalDecoder>

Source§

fn crack(&self, text: &str, checker: &CheckerTypes) -> CrackResult

This function does the actual decoding It returns an Option if it was successful Else the Option returns nothing and the error is logged in Trace

Source§

fn get_tags(&self) -> &Vec<&str>

Gets all tags for this decoder

Source§

fn get_name(&self) -> &str

Gets the name for the current decoder

Source§

fn new() -> Decoder<HexadecimalDecoder>

This function generates a new crack trait
Source§

impl Crack for Decoder<MorseCodeDecoder>

Source§

fn crack(&self, text: &str, checker: &CheckerTypes) -> CrackResult

This function does the actual decoding It returns an Option if it was successful Else the Option returns nothing and the error is logged in Trace

Source§

fn get_tags(&self) -> &Vec<&str>

Gets all tags for this decoder

Source§

fn get_name(&self) -> &str

Gets the name for the current decoder

Source§

fn new() -> Decoder<MorseCodeDecoder>

This function generates a new crack trait
Source§

impl Crack for Decoder<ReverseDecoder>

Source§

fn crack(&self, text: &str, checker: &CheckerTypes) -> CrackResult

This function does the actual decoding It returns an Option if it was successful Else the Option returns nothing and the error is logged in Trace

Source§

fn get_tags(&self) -> &Vec<&str>

Gets all tags for this decoder

Source§

fn get_name(&self) -> &str

Gets the name for the current decoder

Source§

fn new() -> Decoder<ReverseDecoder>

This function generates a new crack trait
Source§

impl Default for Decoder<DefaultDecoder>

Source§

fn default() -> Decoder<DefaultDecoder>

Returns the “default value” for a type. Read more

Auto Trait Implementations§

§

impl<Type> Freeze for Decoder<Type>

§

impl<Type> RefUnwindSafe for Decoder<Type>
where Type: RefUnwindSafe,

§

impl<Type> Send for Decoder<Type>
where Type: Send,

§

impl<Type> Sync for Decoder<Type>
where Type: Sync,

§

impl<Type> Unpin for Decoder<Type>
where Type: Unpin,

§

impl<Type> UnwindSafe for Decoder<Type>
where Type: UnwindSafe,

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> IntoEither for T

Source§

fn into_either(self, into_left: bool) -> Either<Self, Self>

Converts 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 more
Source§

fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
where F: FnOnce(&Self) -> bool,

Converts 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
Source§

impl<T> Pointable for T

Source§

const ALIGN: usize

The alignment of pointer.
Source§

type Init = T

The type for initializers.
Source§

unsafe fn init(init: <T as Pointable>::Init) -> usize

Initializes a with the given initializer. Read more
Source§

unsafe fn deref<'a>(ptr: usize) -> &'a T

Dereferences the given pointer. Read more
Source§

unsafe fn deref_mut<'a>(ptr: usize) -> &'a mut T

Mutably dereferences the given pointer. Read more
Source§

unsafe fn drop(ptr: usize)

Drops the object pointed to by the given pointer. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

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

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.