The vulnerability is a heap-based buffer over-read that exists in multiple functions responsible for reading raw pixel data for various image formats (BGR, CMYK, GRAY, RAW, RGB, and YCbCr). The core of the issue lies in the way ImageMagick handles image processing when the -extract dimension is larger than the -size dimension. In the vulnerable versions, the loop that iterates over the image's columns to read pixel data used the width from the -extract option (image->columns) as its boundary. However, the buffer (canvas_image) from which the data was being read was allocated based on the -size dimension. When a larger -extract width was provided, the loop would attempt to read past the end of the allocated canvas_image buffer, resulting in a heap buffer over-read. The patch addresses this by calculating the number of columns to read as the minimum of the -extract width and the canvas_image width. This ensures that the read operation remains within the bounds of the allocated buffer, thereby mitigating the vulnerability. The identified vulnerable functions are the Read*Image functions within their respective coder files, as these are the functions that contain the flawed loop logic.