pub enum XFrameOptions {
Deny,
SameOrigin,
}Expand description
XFrameOptions sets the X-Frame-Options header to help you mitigate clickjacking attacks.
This header is superseded by the frame-ancestors Content Security Policy directive but is still useful on old browsers.
For more, see helmet.contentSecurityPolicy, as well as the documentation on MDN.
DENY or SAMEORIGIN. (A legacy directive, ALLOW-FROM, is not supported by this crate. Read more here.)
Variants§
Trait Implementations§
Source§impl Clone for XFrameOptions
impl Clone for XFrameOptions
Source§fn clone(&self) -> XFrameOptions
fn clone(&self) -> XFrameOptions
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreimpl Copy for XFrameOptions
Source§impl Debug for XFrameOptions
impl Debug for XFrameOptions
Source§impl Default for XFrameOptions
impl Default for XFrameOptions
Source§fn default() -> XFrameOptions
fn default() -> XFrameOptions
Returns the “default value” for a type. Read more
Source§impl Display for XFrameOptions
impl Display for XFrameOptions
Source§impl IntoHeader for XFrameOptions
impl IntoHeader for XFrameOptions
fn header_name(&self) -> HeaderName
fn header_value(&self) -> Result<HeaderValue, InvalidHeaderValue>
Auto Trait Implementations§
impl Freeze for XFrameOptions
impl RefUnwindSafe for XFrameOptions
impl Send for XFrameOptions
impl Sync for XFrameOptions
impl Unpin for XFrameOptions
impl UnsafeUnpin for XFrameOptions
impl UnwindSafe for XFrameOptions
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