pub enum GatekeepRejection<Resolve, Audit> {
Denied(DenialResponse),
Error(GatekeepAxumError<Resolve, Audit>),
}Expand description
Axum rejection returned by crate::Gatekeeper::authorize.
Variants§
Denied(DenialResponse)
The policy denied the request.
Error(GatekeepAxumError<Resolve, Audit>)
The authorization boundary failed before a response could be trusted.
Trait Implementations§
Source§impl<Resolve, Audit> From<DenialResponse> for GatekeepRejection<Resolve, Audit>
impl<Resolve, Audit> From<DenialResponse> for GatekeepRejection<Resolve, Audit>
Source§fn from(response: DenialResponse) -> Self
fn from(response: DenialResponse) -> Self
Converts to this type from the input type.
Source§impl<Resolve, Audit> From<GatekeepAxumError<Resolve, Audit>> for GatekeepRejection<Resolve, Audit>
impl<Resolve, Audit> From<GatekeepAxumError<Resolve, Audit>> for GatekeepRejection<Resolve, Audit>
Source§fn from(error: GatekeepAxumError<Resolve, Audit>) -> Self
fn from(error: GatekeepAxumError<Resolve, Audit>) -> Self
Converts to this type from the input type.
Source§impl<Resolve, Audit> IntoResponse for GatekeepRejection<Resolve, Audit>
impl<Resolve, Audit> IntoResponse for GatekeepRejection<Resolve, Audit>
Source§fn into_response(self) -> Response
fn into_response(self) -> Response
Create a response.
Auto Trait Implementations§
impl<Resolve, Audit> !RefUnwindSafe for GatekeepRejection<Resolve, Audit>
impl<Resolve, Audit> !UnwindSafe for GatekeepRejection<Resolve, Audit>
impl<Resolve, Audit> Freeze for GatekeepRejection<Resolve, Audit>
impl<Resolve, Audit> Send for GatekeepRejection<Resolve, Audit>
impl<Resolve, Audit> Sync for GatekeepRejection<Resolve, Audit>
impl<Resolve, Audit> Unpin for GatekeepRejection<Resolve, Audit>
impl<Resolve, Audit> UnsafeUnpin for GatekeepRejection<Resolve, Audit>where
Audit: UnsafeUnpin,
Resolve: UnsafeUnpin,
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