pub struct Config {
pub max_document_bytes: u64,
pub connect_timeout: Duration,
pub request_timeout: Duration,
pub allow_local: bool,
}Expand description
Limits applied while resolving. The defaults assume DIDs arrive from untrusted input.
Fields§
§max_document_bytes: u64Rejects documents larger than this, streaming the body so an oversized or dishonestly-framed response is abandoned rather than buffered.
connect_timeout: Duration§request_timeout: Duration§allow_local: boolPermits loopback, private and link-local targets, and plaintext HTTP for
localhost. Needed to resolve against a local server; an SSRF vector
whenever the DID being resolved is attacker-controlled.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Config
impl RefUnwindSafe for Config
impl Send for Config
impl Sync for Config
impl Unpin for Config
impl UnsafeUnpin for Config
impl UnwindSafe for Config
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