mirror of
https://github.com/imgproxy/imgproxy.git
synced 2025-09-29 04:53:05 +02:00
Add IMGPROXY_MAX_RESULT_DIMENSION
config and max_result_dimension
processing option
This commit is contained in:
@@ -47,6 +47,7 @@ var (
|
||||
MaxRedirects int
|
||||
PngUnlimited bool
|
||||
SvgUnlimited bool
|
||||
MaxResultDimension int
|
||||
AllowSecurityOptions bool
|
||||
|
||||
JpegProgressive bool
|
||||
@@ -252,6 +253,7 @@ func Reset() {
|
||||
MaxRedirects = 10
|
||||
PngUnlimited = false
|
||||
SvgUnlimited = false
|
||||
MaxResultDimension = 0
|
||||
AllowSecurityOptions = false
|
||||
|
||||
JpegProgressive = false
|
||||
@@ -483,6 +485,8 @@ func Configure() error {
|
||||
configurators.Bool(&PngUnlimited, "IMGPROXY_PNG_UNLIMITED")
|
||||
configurators.Bool(&SvgUnlimited, "IMGPROXY_SVG_UNLIMITED")
|
||||
|
||||
configurators.Int(&MaxResultDimension, "IMGPROXY_MAX_RESULT_DIMENSION")
|
||||
|
||||
configurators.Bool(&AllowSecurityOptions, "IMGPROXY_ALLOW_SECURITY_OPTIONS")
|
||||
|
||||
configurators.Bool(&JpegProgressive, "IMGPROXY_JPEG_PROGRESSIVE")
|
||||
|
Reference in New Issue
Block a user