[−][src]Module http_types::security
HTTP Security Headers.
Specifications
Example
use http_types::{StatusCode, Response}; let mut res = Response::new(StatusCode::Ok); http_types::security::default(&mut res);
Structs
| ContentSecurityPolicy | Build a |
| ReportTo | Define |
| ReportToEndpoint | Define |
| TimingAllowOrigin | Specify origins that are allowed to see values via the Resource Timing API. |
Enums
| FrameOptions | Set the frameguard level. |
| ReferrerOptions | Set the Referrer-Policy level |
| Source | Define source value |
Functions
| default | Apply a set of default protections. |
| dns_prefetch_control | Disable browsers’ DNS prefetching by setting the |
| frameguard | Mitigates clickjacking attacks by setting the |
| hsts | Sets the |
| nosniff | Prevent browsers from trying to guess (“sniff”) the MIME type, which can have security implications. |
| powered_by | Removes the |
| referrer_policy | Mitigates referrer leakage by controlling the referer[sic] header in links away from pages |
| xss_filter | Sets the |