pub struct HttpConfig {
pub deny_response: bool,
pub deny_message: Option<String>,
}Expand description
HTTP responses returned when network policy denies a request.
Fields§
§deny_response: boolReturn readable HTTP 403 responses for supported denied requests. Default: false.
deny_message: Option<String>Denial response body. {host} names the blocked host.
Used only when deny_response is enabled. Omission uses the default;
an empty string produces an empty body.
Trait Implementations§
Source§impl Clone for HttpConfig
impl Clone for HttpConfig
Source§impl Debug for HttpConfig
impl Debug for HttpConfig
Source§impl Default for HttpConfig
impl Default for HttpConfig
Source§impl<'de> Deserialize<'de> for HttpConfigwhere
HttpConfig: Default,
impl<'de> Deserialize<'de> for HttpConfigwhere
HttpConfig: Default,
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 From<HttpConfig> for HttpConfigPatch
impl From<HttpConfig> for HttpConfigPatch
Source§fn from(value: HttpConfig) -> Self
fn from(value: HttpConfig) -> Self
Converts to this type from the input type.
Auto Trait Implementations§
impl Freeze for HttpConfig
impl RefUnwindSafe for HttpConfig
impl Send for HttpConfig
impl Sync for HttpConfig
impl Unpin for HttpConfig
impl UnsafeUnpin for HttpConfig
impl UnwindSafe for HttpConfig
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