pub struct OutstandingLogout { /* private fields */ }Expand description
A LogoutRequest the caller has already accepted.
Pass it to Saml<Sp>::finish_sso_with_outstanding_logout or
Saml<Sp>::accept_unsolicited_sso_with_outstanding_logout. The library
does not store it. NameID values must be equal. A Format on the logout
must match; an omitted Format compares values only. An empty session list
applies to every session of that principal. The classification is in
docs/conformance/web-browser-sso-acceptance.md.
§Examples
use saml_rs::{NameId, NameIdFormat, OutstandingLogout, SamlInstant, SessionIndex};
let logout = OutstandingLogout::try_new(
NameId::new(
"alice@example.com",
Some(NameIdFormat::EmailAddress),
),
vec![SessionIndex::try_new("_session")?],
SamlInstant::try_new("2026-10-06T00:00:00Z")?,
)?;Implementations§
Source§impl OutstandingLogout
impl OutstandingLogout
Sourcepub fn try_new(
principal: NameId,
sessions: Vec<SessionIndex>,
not_on_or_after: SamlInstant,
) -> Result<OutstandingLogout, SamlError>
pub fn try_new( principal: NameId, sessions: Vec<SessionIndex>, not_on_or_after: SamlInstant, ) -> Result<OutstandingLogout, SamlError>
Create an outstanding logout from the principal, sessions, and
NotOnOrAfter the caller accepted.
§Errors
Returns SamlError::Invalid when the principal value is empty or
not_on_or_after is not a representable SAML UTC xs:dateTime.
Sourcepub fn sessions(&self) -> &[SessionIndex]
pub fn sessions(&self) -> &[SessionIndex]
Sessions named by the accepted logout.
Empty means the logout carried no SessionIndex.
Sourcepub fn not_on_or_after(&self) -> &SamlInstant
pub fn not_on_or_after(&self) -> &SamlInstant
NotOnOrAfter from the accepted logout, normalized as a SAML UTC instant.
Trait Implementations§
Source§impl Clone for OutstandingLogout
impl Clone for OutstandingLogout
Source§fn clone(&self) -> OutstandingLogout
fn clone(&self) -> OutstandingLogout
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more