From be531eaab7f13ea935aaef231473044a439c9bfc Mon Sep 17 00:00:00 2001 From: Cristy Date: Sat, 24 Jun 2017 08:29:07 -0400 Subject: [PATCH] https://github.com/ImageMagick/ImageMagick/issues/523 --- coders/dpx.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/coders/dpx.c b/coders/dpx.c index cb9870dad..0d5694972 100644 --- a/coders/dpx.c +++ b/coders/dpx.c @@ -1106,6 +1106,8 @@ static Image *ReadDPXImage(const ImageInfo *image_info,ExceptionInfo *exception) StringInfo *profile; + if (dpx.file.user_size > GetBlobSize(image)) + ThrowReaderException(CorruptImageError,"ImproperImageHeader"); profile=BlobToStringInfo((const unsigned char *) NULL, dpx.file.user_size-sizeof(dpx.user.id)); if (profile == (StringInfo *) NULL) -- 2.40.0