Table of Contents

Class WebPLimits

Namespace
Imazen.WebP
Assembly
Imazen.WebP.dll

Process-wide resource limits applied by the managed WebP wrappers before any data reaches libwebp. Adjust before the first decode if you accept WebP data from untrusted sources (HTTP uploads, peer-to-peer transfers, etc.) so a hostile or buggy producer cannot drive the process out of memory.

public static class WebPLimits
Inheritance
WebPLimits
Inherited Members

Properties

MaxDecodeStreamBytes

Default cap on DecodeFromStream-style APIs that buffer the entire encoded WebP into memory before handing it to libwebp. Default: int.MaxValue bytes (effectively unlimited), to preserve historical behavior. Lower this when accepting WebP data from untrusted streams. Callers can also override on a per-call basis via the maxBytes overloads.

public static long MaxDecodeStreamBytes { get; set; }

Property Value

long