pub struct BasicAuthContextConfig<Creds>{
pub creds: BasicAuthCredsConfig<Creds>,
pub real_ip_access: Option<RealIpAccessConfig>,
pub zones: Vec<BasicAuthZoneConfig>,
pub realm: Option<String>,
pub post_auth_redirect: RedirectTargetConfig,
}Fields§
§creds: BasicAuthCredsConfig<Creds>§real_ip_access: Option<RealIpAccessConfig>§zones: Vec<BasicAuthZoneConfig>§realm: Option<String>§post_auth_redirect: RedirectTargetConfigImplementations§
Source§impl<Creds> BasicAuthContextConfig<Creds>
impl<Creds> BasicAuthContextConfig<Creds>
Sourcepub fn builder() -> BasicAuthContextConfigBuilder<Creds, ((), (), (), (), ())>
pub fn builder() -> BasicAuthContextConfigBuilder<Creds, ((), (), (), (), ())>
Create a builder for building BasicAuthContextConfig.
On the builder, call .creds(...)(optional), .real_ip_access(...)(optional), .zones(...)(optional), .realm(...)(optional), .post_auth_redirect(...)(optional) to set the values of the fields.
Finally, call .build() to create the instance of BasicAuthContextConfig.
Trait Implementations§
Source§impl<Creds> BasicAuthContextConfigSource<Creds> for BasicAuthContextConfig<Creds>
impl<Creds> BasicAuthContextConfigSource<Creds> for BasicAuthContextConfig<Creds>
fn creds_config(&self) -> &BasicAuthCredsConfig<Creds>
fn real_ip_access_config(&self) -> Option<&RealIpAccessConfig>
fn zones_config(&self) -> &[BasicAuthZoneConfig]
fn realm_config(&self) -> Option<&str>
fn post_auth_redirect_config(&self) -> &RedirectTargetConfig
fn resolve_creds_config(&self) -> BasicAuthCredsConfig<Creds>where
Creds: Clone,
fn resolve_real_ip_access_config( &self, ) -> BasicAuthContextResult<Option<RealIpAccessConfig>>
fn resolve_realm_config(&self) -> String
fn resolve_post_auth_redirect_config( &self, ) -> BasicAuthContextResult<RedirectTargetConfig>
fn resolve_zones_config( &self, default_realm: &str, default_post_auth_redirect: &RedirectTargetConfig, ) -> BasicAuthContextResult<Vec<ResolvedBasicAuthZoneConfig>>
fn resolve_all(
&self,
) -> Result<ResolvedBasicAuthContextConfig<Creds>, BasicAuthContextConfigBuildError>where
Creds: Clone,
fn resolve_all_with_validator<V>(
&self,
validator: &V,
) -> Result<ResolvedBasicAuthContextConfig<Creds>, BasicAuthContextConfigBuildError>where
Creds: Clone,
V: BasicAuthContextConfigValidator<Creds>,
Source§impl<Creds> Clone for BasicAuthContextConfig<Creds>
impl<Creds> Clone for BasicAuthContextConfig<Creds>
Source§fn clone(&self) -> BasicAuthContextConfig<Creds>
fn clone(&self) -> BasicAuthContextConfig<Creds>
Returns a duplicate 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 moreSource§impl<Creds> Debug for BasicAuthContextConfig<Creds>
impl<Creds> Debug for BasicAuthContextConfig<Creds>
Source§impl<Creds> Default for BasicAuthContextConfig<Creds>
impl<Creds> Default for BasicAuthContextConfig<Creds>
Source§impl<'de, Creds> Deserialize<'de> for BasicAuthContextConfig<Creds>
impl<'de, Creds> Deserialize<'de> for BasicAuthContextConfig<Creds>
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl<Creds> Serialize for BasicAuthContextConfig<Creds>
impl<Creds> Serialize for BasicAuthContextConfig<Creds>
Auto Trait Implementations§
impl<Creds> Freeze for BasicAuthContextConfig<Creds>
impl<Creds> RefUnwindSafe for BasicAuthContextConfig<Creds>where
Creds: RefUnwindSafe,
impl<Creds> Send for BasicAuthContextConfig<Creds>where
Creds: Send,
impl<Creds> Sync for BasicAuthContextConfig<Creds>where
Creds: Sync,
impl<Creds> Unpin for BasicAuthContextConfig<Creds>where
Creds: Unpin,
impl<Creds> UnsafeUnpin for BasicAuthContextConfig<Creds>
impl<Creds> UnwindSafe for BasicAuthContextConfig<Creds>where
Creds: UnwindSafe,
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