1. An image reading apparatus comprising: an image data reading unit that has, for each color component, a line sensor in which a plurality of light-receiving elements corresponding to pixels are arranged one-dimensionally, and that acquires image data for each color component in which an intensity of reflected light from a read position on a contact glass where a document is conveyed is converted into density values for each pixel by guiding the reflected light to the line sensors; a provisional foreign matter region detection unit that, when an adjacent density variation amount representing a variation amount of a density value between a target pixel and a pixel adjacent to this target pixel in image data of one color component selected from the image data of each color component exceeds a predetermined first reference value, takes the target pixel as a lead pixel, in sequential comparison of a density value of each pixel arranged in series with the lead pixel with the density value of the lead pixel, takes the very first pixel having a density value equal to or greater than the density value of the target pixel as an end pixel, and detects a pixel group continuing from the lead pixel to the end pixel as a provisional foreign matter region in the image data of the one color component; a first condition determination unit that, when the provisional foreign matter region detection unit detects a provisional foreign matter region in the image data of the selected one color component and the number of pixels constituting the provisional foreign matter region is less than a predetermined second reference value, determines that a first condition of foreign matter being present at a read position corresponding to a line sensor that has read the image data of the selected one color component is satisfied; a second condition determination unit that, when the first condition is determined by the first condition determination unit to be satisfied and an average value of density values of all of the pixels within the provisional foreign matter region is equal to or greater than a predetermined third reference value, determines that a second condition of foreign matter being present at a read position corresponding to the line sensor that has read the image data of the selected one color component is satisfied; and a foreign matter determination unit that performs a foreign matter determination processing that, when the second condition is determined by the second condition determination unit to be satisfied and a difference between the density value of the pixel corresponding to the lead pixel in the provisional foreign matter region and an average value of the density values of the pixels corresponding to all of the pixels in the provisional foreign matter region in the image data of any one color component from among color components other than the selected one color component is less than a predetermined fourth reference value, determines that foreign matter is present at the read position corresponding to the line sensor that has read the image data of the selected one color component.