pub struct ShareLink {
pub link_id: ShareLinkId,
pub opaque_id: [u8; 16],
pub scope: ShareScope,
pub fragment_secret: [u8; 32],
pub wrapped_scope: WrappedScope,
pub expires_at: Option<String>,
}Expand description
An issued share link: the server-held record fields plus the fragment secret the issuing client places in the URL. The fragment secret never leaves the client.
Fields§
§link_id: ShareLinkIdRevocation handle.
opaque_id: [u8; 16]The random 128-bit opaque id (URL path component; never structured/UUIDv7).
scope: ShareScopeWhat the link grants access to.
fragment_secret: [u8; 32]The URL fragment #{secret} — the random link secret. Never sent to the
server; the server holds only wrapped_scope.
wrapped_scope: WrappedScopeThe server-held, opaque encapsulation of the scope material.
expires_at: Option<String>RFC 3339 expiry, if any.
Implementations§
Sourcepub fn opaque_id_hex(&self) -> String
pub fn opaque_id_hex(&self) -> String
Lowercase-hex of the opaque URL-path id.
Sourcepub fn fragment_hex(&self) -> String
pub fn fragment_hex(&self) -> String
Lowercase-hex of the URL fragment secret (the #{secret} component).
Sourcepub fn is_passphrase_protected(&self) -> bool
pub fn is_passphrase_protected(&self) -> bool
Whether the link is passphrase-protected (an Argon2id layer wraps the material).
Trait Implementations§
Auto Trait Implementations§
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
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 moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
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