[−][src]Struct torut::onion::OnionAddressV2
OnionAddressV2 contains public part of Tor's onion service address version 2. It can't contain invalid onion address(
Public key
Unlike onion address V3 onion address V2 does not contain public key which has to be fetched from relay. This means that public key can't be extracted from this representation. Creating address from key is one way function.
Note
Onion address V2 does not contain checksum so any combination of random ten bytes satisfies requirements. Since it may be valid SHA1 bytes.
Docs
https://gitweb.torproject.org/torspec.git/tree/rend-spec-v2.txt#n530
Implementations
impl OnionAddressV2
[src]
pub fn get_address_without_dot_onion(&self) -> String
[src]
pub fn get_raw_bytes(&self) -> [u8; 10]
[src]
Trait Implementations
impl Clone for OnionAddressV2
[src]
pub fn clone(&self) -> OnionAddressV2
[src]
pub fn clone_from(&mut self, source: &Self)
1.0.0[src]
impl Copy for OnionAddressV2
[src]
impl Debug for OnionAddressV2
[src]
impl<'de> Deserialize<'de> for OnionAddressV2
[src]
pub fn deserialize<D>(
deserializer: D
) -> Result<Self, <D as Deserializer<'de>>::Error> where
D: Deserializer<'de>,
[src]
deserializer: D
) -> Result<Self, <D as Deserializer<'de>>::Error> where
D: Deserializer<'de>,
impl Display for OnionAddressV2
[src]
impl Eq for OnionAddressV2
[src]
impl From<OnionAddressV2> for OnionAddress
[src]
pub fn from(original: OnionAddressV2) -> OnionAddress
[src]
impl FromStr for OnionAddressV2
[src]
type Err = OnionAddressV2ParseError
The associated error which can be returned from parsing.
pub fn from_str(raw_onion_address: &str) -> Result<Self, Self::Err>
[src]
impl PartialEq<OnionAddressV2> for OnionAddressV2
[src]
pub fn eq(&self, other: &Self) -> bool
[src]
#[must_use]pub fn ne(&self, other: &Rhs) -> bool
1.0.0[src]
impl Serialize for OnionAddressV2
[src]
pub fn serialize<S>(
&self,
serializer: S
) -> Result<<S as Serializer>::Ok, <S as Serializer>::Error> where
S: Serializer,
[src]
&self,
serializer: S
) -> Result<<S as Serializer>::Ok, <S as Serializer>::Error> where
S: Serializer,
impl TryFrom<OnionAddress> for OnionAddressV2
[src]
Auto Trait Implementations
impl RefUnwindSafe for OnionAddressV2
impl Send for OnionAddressV2
impl Sync for OnionAddressV2
impl Unpin for OnionAddressV2
impl UnwindSafe for OnionAddressV2
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
pub fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> DeserializeOwned for T where
T: for<'de> Deserialize<'de>,
[src]
T: for<'de> Deserialize<'de>,
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> Same<T> for T
type Output = T
Should always be Self
impl<T> ToOwned for T where
T: Clone,
[src]
T: Clone,
type Owned = T
The resulting type after obtaining ownership.
pub fn to_owned(&self) -> T
[src]
pub fn clone_into(&self, target: &mut T)
[src]
impl<T> ToString for T where
T: Display + ?Sized,
[src]
T: Display + ?Sized,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
pub fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
pub fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<V, T> VZip<V> for T where
V: MultiLane<T>,
V: MultiLane<T>,