Branch: Tag:

2015-02-01

2015-02-01 22:57:02 by Martin Nilsson <nilsson@opera.com>

Verify that the algorithm identifiers match in the certificate.

1398:       TBSCertificate tbs = TBSCertificate()->init(cert[0]);    +  // FIXME: The re-encoding and algorithm checks are more appropriate +  // in verify_certificate, but the full certificate doesn't reach +  // there.    if (!tbs || (cert[1]->get_der() != tbs->algorithm->get_der()))    return NULL("Failed to generate TBSCertificate.\n");    -  +  if(tbs->algorithm->get_der() != cert[1]->get_der()) +  return NULL("Mismatching algorithm identifiers.\n"); +     return tbs;   }