pub struct PendingResumingWelcome { /* private fields */ }Expand description
A Welcome whose group secrets have been decrypted, but whose GroupInfo
has not.
This lets a receiver read which parent group and epoch the group branches from before
committing to a BranchInfo, or which old group’s resumption psk to inject for reinit.
The decrypted state is carried here and reused when finishing the join.
Create it with StagedWelcome::process_resuming_welcome, read the PSK
reference with Self::required_resumption_secret, then finish with
Self::build_from_branch, Self::build_from_reinit, or Self::build.
Implementations§
Source§impl PendingResumingWelcome
impl PendingResumingWelcome
Sourcepub fn required_resumption_secret(&self) -> Option<&ResumptionPsk>
pub fn required_resumption_secret(&self) -> Option<&ResumptionPsk>
The PSK pointing to the parent group and epoch for branch or old group and final epoch for reinit, if any.
The returned ResumptionPsk has a usage of either Reinit or Branch
Sourcepub fn build<Provider: OpenMlsProvider>(
self,
provider: &Provider,
) -> Result<ProcessedWelcome, WelcomeError<Provider::StorageError>>
pub fn build<Provider: OpenMlsProvider>( self, provider: &Provider, ) -> Result<ProcessedWelcome, WelcomeError<Provider::StorageError>>
Finish processing without injecting a PSK.
Use this method if the welcome does not need a PSK, indicated by Self::required_resumption_secret returning None.
This has the same effect as ProcessedWelcome::new_from_welcome
Sourcepub fn build_from_reinit<'a, Provider: OpenMlsProvider>(
self,
provider: &'a Provider,
reinit_info: ReInitInfo,
) -> Result<JoinBuilder<'a, Provider>, WelcomeError<Provider::StorageError>>
pub fn build_from_reinit<'a, Provider: OpenMlsProvider>( self, provider: &'a Provider, reinit_info: ReInitInfo, ) -> Result<JoinBuilder<'a, Provider>, WelcomeError<Provider::StorageError>>
Prepare the reinit join with the selected ReInitInfo.
The reinit PSK’s reference is checked against reinit_info (see
StagedWelcome::build_from_reinit); a reinit_info from the wrong
group or epoch fails with WelcomeError::ReInitPredecessorMismatch. The
remaining receiver checks run when JoinBuilder::build is called.
Sourcepub fn build_from_branch<'a, Provider: OpenMlsProvider>(
self,
provider: &'a Provider,
branch_info: BranchInfo,
) -> Result<JoinBuilder<'a, Provider>, WelcomeError<Provider::StorageError>>
pub fn build_from_branch<'a, Provider: OpenMlsProvider>( self, provider: &'a Provider, branch_info: BranchInfo, ) -> Result<JoinBuilder<'a, Provider>, WelcomeError<Provider::StorageError>>
Prepare the subgroup-branch join with the selected BranchInfo.
The branch PSK’s parent reference is checked against branch_info (see
StagedWelcome::build_from_branch); a branch_info from the wrong
parent epoch fails with WelcomeError::SubgroupParentMismatch. The
remaining receiver checks run when JoinBuilder::build is called.
Auto Trait Implementations§
impl Freeze for PendingResumingWelcome
impl RefUnwindSafe for PendingResumingWelcome
impl Send for PendingResumingWelcome
impl Sync for PendingResumingWelcome
impl Unpin for PendingResumingWelcome
impl UnsafeUnpin for PendingResumingWelcome
impl UnwindSafe for PendingResumingWelcome
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
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> ⓘ
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> ⓘ
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