pub enum XPermittedCrossDomainPolicies {
None,
MasterOnly,
ByContentType,
ByFtpFilename,
All,
}
Expand description
Manages X-Permitted-Cross-Domain-Policies
header
The X-Permitted-Cross-Domain-Policies HTTP response header determines whether cross-domain policy files (crossdomain.xml and clientaccesspolicy.xml) will be ignored by Flash and Adobe Acrobat in subsequent requests.
§Values
- none: No policy file is allowed.
- master-only: Only a master policy file, but no other policy files, is allowed.
- by-content-type: A policy file is allowed if its MIME type matches the Content-Type of the requested resource.
- by-ftp-filename: A policy file is allowed if its URL matches the URL of the requested resource.
- all: Any policy file is allowed.
§Examples
use helmet_core::XPermittedCrossDomainPolicies;
let x_permitted_cross_domain_policies = XPermittedCrossDomainPolicies::none();
let x_permitted_cross_domain_policies = XPermittedCrossDomainPolicies::master_only();
let x_permitted_cross_domain_policies = XPermittedCrossDomainPolicies::by_content_type();
let x_permitted_cross_domain_policies = XPermittedCrossDomainPolicies::by_ftp_filename();
let x_permitted_cross_domain_policies = XPermittedCrossDomainPolicies::all();
Variants§
Implementations§
Source§impl XPermittedCrossDomainPolicies
impl XPermittedCrossDomainPolicies
pub fn none() -> Self
pub fn master_only() -> Self
pub fn by_content_type() -> Self
pub fn by_ftp_filename() -> Self
pub fn all() -> Self
Trait Implementations§
Source§impl Clone for XPermittedCrossDomainPolicies
impl Clone for XPermittedCrossDomainPolicies
Source§fn clone(&self) -> XPermittedCrossDomainPolicies
fn clone(&self) -> XPermittedCrossDomainPolicies
Returns a copy of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreAuto Trait Implementations§
impl Freeze for XPermittedCrossDomainPolicies
impl RefUnwindSafe for XPermittedCrossDomainPolicies
impl Send for XPermittedCrossDomainPolicies
impl Sync for XPermittedCrossDomainPolicies
impl Unpin for XPermittedCrossDomainPolicies
impl UnwindSafe for XPermittedCrossDomainPolicies
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