; and (ii) in the case of a ballot marking device intended to be used by the State or jurisdiction, the device meets the requirements of section 301(a)(12)(A) of such Act. (B) Optional testing of State requirements In the case of a ballot marking device or ballot tabulation device for which the source code has been published under an open source license, the contract under subparagraph (A) shall also include, at the request of any State or jurisdiction, testing of whether such device meets any applicable requirements of the State or jurisdiction. (2) Requirements for testing Any contract described in paragraph (1) shall require the qualified research laboratory to— (A) not later than 30 days before testing begins, submit to the Director for approval the protocol for the simulated election scenario used for testing the security of the ballot marking device or ballot tabulation device, as the case may be; (B) use only protocols approved by the Director in conducting such security testing; and (C) submit to the Director a report on the results of the security testing. (3) Qualified research laboratory For purposes of this section, the term qualified research laboratory means a laboratory accredited under this subsection by the Director, in consultation with the Director of the National Institute of Standards and Technology. (c) Reporting and certification The Director shall— (1) publish on the website of the Cybersecurity and Infrastructure Security Agency the results of the testing conducted under subsection (b); and (2) certify— (A) a ballot tabulation device if the ballot tabulation device is determined by the qualified research laboratory to meet the requirements of section 301(a)(9)(B) of the Help America Vote Act of 2002