pub struct CaepManager { /* private fields */ }Expand description
Main CAEP manager for continuous access evaluation
Implementations§
Source§impl CaepManager
impl CaepManager
Sourcepub async fn new(
config: CaepConfig,
session_manager: Arc<SessionManager>,
logout_manager: Arc<BackChannelLogoutManager>,
) -> Result<Self>
pub async fn new( config: CaepConfig, session_manager: Arc<SessionManager>, logout_manager: Arc<BackChannelLogoutManager>, ) -> Result<Self>
Create a new CAEP manager
Sourcepub fn with_step_up_manager(
self,
step_up_manager: Arc<SteppedUpAuthManager>,
) -> Self
pub fn with_step_up_manager( self, step_up_manager: Arc<SteppedUpAuthManager>, ) -> Self
Set step-up authentication manager
Sourcepub async fn register_event_handler(
&self,
event_type: CaepEventType,
handler: Arc<dyn CaepEventHandler>,
) -> Result<()>
pub async fn register_event_handler( &self, event_type: CaepEventType, handler: Arc<dyn CaepEventHandler>, ) -> Result<()>
Register an event handler
Sourcepub async fn process_event(
&self,
event: CaepEvent,
) -> Result<CaepEvaluationResult>
pub async fn process_event( &self, event: CaepEvent, ) -> Result<CaepEvaluationResult>
Process a CAEP event
Sourcepub async fn evaluate_access(
&self,
subject: &str,
triggering_event: Option<&CaepEvent>,
) -> Result<CaepEvaluationResult>
pub async fn evaluate_access( &self, subject: &str, triggering_event: Option<&CaepEvent>, ) -> Result<CaepEvaluationResult>
Evaluate continuous access for a subject
Sourcepub async fn start_continuous_evaluation(&mut self) -> Result<()>
pub async fn start_continuous_evaluation(&mut self) -> Result<()>
Start continuous evaluation loop
Sourcepub async fn revoke_subject_access(&self, subject: &str) -> Result<()>
pub async fn revoke_subject_access(&self, subject: &str) -> Result<()>
Revoke access for a subject
Sourcepub async fn get_session_state(
&self,
session_id: &str,
) -> Result<Option<CaepSessionState>>
pub async fn get_session_state( &self, session_id: &str, ) -> Result<Option<CaepSessionState>>
Get current session state
Sourcepub async fn get_event_history(
&self,
subject: &str,
limit: Option<usize>,
) -> Result<Vec<CaepEvent>>
pub async fn get_event_history( &self, subject: &str, limit: Option<usize>, ) -> Result<Vec<CaepEvent>>
Get event history for a subject
Sourcepub async fn add_evaluation_rule(&self, rule: CaepEvaluationRule) -> Result<()>
pub async fn add_evaluation_rule(&self, rule: CaepEvaluationRule) -> Result<()>
Add or update an evaluation rule
Sourcepub async fn remove_evaluation_rule(&self, rule_id: &str) -> Result<bool>
pub async fn remove_evaluation_rule(&self, rule_id: &str) -> Result<bool>
Remove an evaluation rule
Sourcepub async fn get_comprehensive_session_info(
&self,
session_id: &str,
) -> Result<Option<ComprehensiveSessionInfo>>
pub async fn get_comprehensive_session_info( &self, session_id: &str, ) -> Result<Option<ComprehensiveSessionInfo>>
Get comprehensive session information combining OIDC and CAEP data
Sourcepub async fn get_subject_sessions(
&self,
subject: &str,
) -> Result<Vec<ComprehensiveSessionInfo>>
pub async fn get_subject_sessions( &self, subject: &str, ) -> Result<Vec<ComprehensiveSessionInfo>>
Get all sessions for a subject with comprehensive information
Auto Trait Implementations§
impl Freeze for CaepManager
impl !RefUnwindSafe for CaepManager
impl Send for CaepManager
impl Sync for CaepManager
impl Unpin for CaepManager
impl !UnwindSafe for CaepManager
Blanket Implementations§
Source§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
Source§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
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
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§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