Security processing options

This commit is contained in:
DarthSim
2023-02-23 21:11:44 +03:00
parent 15aaadd359
commit 9416168575
12 changed files with 240 additions and 49 deletions

View File

@@ -120,7 +120,7 @@ func transformAnimated(ctx context.Context, img *vips.Image, po *options.Process
framesCount := imath.Min(img.Height()/frameHeight, config.MaxAnimationFrames)
// Double check dimensions because animated image has many frames
if err = security.CheckDimensions(imgWidth, frameHeight, framesCount); err != nil {
if err = security.CheckDimensions(imgWidth, frameHeight, framesCount, po.SecurityOptions); err != nil {
return err
}