pub struct ParserLimits {
pub max_objects: usize,
pub max_string_length: usize,
pub max_array_length: usize,
pub max_dict_entries: usize,
pub max_recursion_depth: u32,
pub max_stream_size: usize,
pub max_decoded_stream_size: usize,
}Expand description
Bounds applied while parsing untrusted input, so a hostile PDF cannot exhaust memory (huge strings, arrays, streams, decompression bombs).
Fields§
§max_objects: usize§max_string_length: usize§max_array_length: usize§max_dict_entries: usize§max_recursion_depth: u32§max_stream_size: usize§max_decoded_stream_size: usizeTrait Implementations§
Source§impl Clone for ParserLimits
impl Clone for ParserLimits
Source§fn clone(&self) -> ParserLimits
fn clone(&self) -> ParserLimits
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreimpl Copy for ParserLimits
Source§impl Debug for ParserLimits
impl Debug for ParserLimits
Auto Trait Implementations§
impl Freeze for ParserLimits
impl RefUnwindSafe for ParserLimits
impl Send for ParserLimits
impl Sync for ParserLimits
impl Unpin for ParserLimits
impl UnsafeUnpin for ParserLimits
impl UnwindSafe for ParserLimits
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