def METHOD_NAME(self, dev_keys: bool = False) -> None:
    self.firmware.validate_code_hashes()
    self.vendor_header.METHOD_NAME(dev_keys)
    digest = self.digest()
    try:
        cosi.METHOD_NAME(
            self.firmware.header.signature,
            digest,
            self.vendor_header.sig_m,
            self.vendor_header.pubkeys,
            self.firmware.header.sigmask,
        )
    except Exception:
        raise util.InvalidSignatureError("Invalid firmware signature.")
    # XXX expiry is not used now
    # now = time.gmtime()
    # if time.gmtime(fw.vendor_header.expiry) < now:
    #     raise ValueError("Vendor header expired.")