An image forming apparatus to which a cartridge including an electronic storage device can detachably be attached, wherein the electronic storage device of said cartridge includes: a first area (401, 601) configured to store control information used for image formation by the image forming apparatus, a second area (402, 602) configured to store determination information used to determine correctness of the control information stored in the first area (401, 601), and a third area (403, 603) configured to store identification information used to identify the cartridge; wherein the image forming apparatus comprises: obtaining means configured to obtain the control information from the first area (401, 601) of the electronic storage device, the identification information from the third area (403, 603) of the electronic storage device, and the determination information from the second area (402, 602) of the electronic storage device according to the identification information obtained from the third area (403, 603); generation means configured to generate generated determination information based on the control information; determination means configured to determine the correctness of the control information based on the control information and the determination information; and control means (113, 114) configured to, if the determination means determines that the control information is correct, control image formation using the control information obtained by the obtaining means; and wherein the determination means is configured to determine the correctness of the control information based on comparison between the determination information according to the identification information and the generated determination information. a first area (401, 601) configured to store control information used for image formation by the image forming apparatus, a second area (402, 602) configured to store determination information used to determine correctness of the control information stored in the first area (401, 601), and a third area (403, 603) configured to store identification information used to identify the cartridge; wherein the image forming apparatus comprises: obtaining means configured to obtain the control information from the first area (401, 601) of the electronic storage device, the identification information from the third area (403, 603) of the electronic storage device, and the determination information from the second area (402, 602) of the electronic storage device according to the identification information obtained from the third area (403, 603); generation means configured to generate generated determination information based on the control information; determination means configured to determine the correctness of the control information based on the control information and the determination information; and control means (113, 114) configured to, if the determination means determines that the control information is correct, control image formation using the control information obtained by the obtaining means; and wherein the determination means is configured to determine the correctness of the control information based on comparison between the determination information according to the identification information and the generated determination information. obtaining means configured to obtain the control information from the first area (401, 601) of the electronic storage device, the identification information from the third area (403, 603) of the electronic storage device, and the determination information from the second area (402, 602) of the electronic storage device according to the identification information obtained from the third area (403, 603); generation means configured to generate generated determination information based on the control information; determination means configured to determine the correctness of the control information based on the control information and the determination information; and control means (113, 114) configured to, if the determination means determines that the control information is correct, control image formation using the control information obtained by the obtaining means; and wherein the determination means is configured to determine the correctness of the control information based on comparison between the determination information according to the identification information and the generated determination information.