pub struct TimeWindowRule {
pub start_hour: u32,
pub end_hour: u32,
}Expand description
Allow signing only during the specified hour range (UTC).
Fields§
§start_hour: u32Start hour (inclusive), 0–23.
end_hour: u32End hour (exclusive), 1–24.
Trait Implementations§
Source§impl Rule for TimeWindowRule
impl Rule for TimeWindowRule
Source§fn evaluate(
&self,
_request: &SessionRequest,
ctx: &PolicyContext,
) -> Result<(), PolicyDenial>
fn evaluate( &self, _request: &SessionRequest, ctx: &PolicyContext, ) -> Result<(), PolicyDenial>
Evaluate the rule. Returns
Ok(()) if allowed, Err(PolicyDenial) if denied.Auto Trait Implementations§
impl Freeze for TimeWindowRule
impl RefUnwindSafe for TimeWindowRule
impl Send for TimeWindowRule
impl Sync for TimeWindowRule
impl Unpin for TimeWindowRule
impl UnsafeUnpin for TimeWindowRule
impl UnwindSafe for TimeWindowRule
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