def METHOD_NAME(core_fw: bytes) -> None:
    core = VendorFirmware.parse(core_fw)
    core.verify()
    modified_data = bytearray(core_fw)
    modified_data[-1] ^= 0x01
    modified = VendorFirmware.parse(modified_data)
    assert modified.digest() != core.digest()
    with pytest.raises(firmware.FirmwareIntegrityError):
        modified.verify()