f29da57ef6
The `std::io::Read` trait includes `read_to_end` but that method provides a denial of service attack vector since an unbounded reader will exhaust all system memory. Add a method to our `Read` trait called `read_to_limit` that does the same as `std::io::Read::read_to_end` but with memory exhaustion protection. Add a `read_to_end` method on our `Take` trait and call through to it from the new method on our `Read` trait called `read_to_limit`. |
||
---|---|---|
.. | ||
error.rs | ||
lib.rs | ||
macros.rs |