| Index: net/cert/x509_certificate_win.cc
|
| diff --git a/net/cert/x509_certificate_win.cc b/net/cert/x509_certificate_win.cc
|
| index df263d8fa90838d9af5fb7db8e72b0eed0ee8f30..0b4c46b00dbcf228350acc120e1913d200053ad6 100644
|
| --- a/net/cert/x509_certificate_win.cc
|
| +++ b/net/cert/x509_certificate_win.cc
|
| @@ -472,4 +472,17 @@ bool X509Certificate::IsIssuedByEncoded(
|
| return false;
|
| }
|
|
|
| +// static
|
| +bool X509Certificate::IsSelfSigned(OSCertHandle cert_handle) {
|
| + return !!CryptVerifyCertificateSignatureEx(
|
| + NULL,
|
| + X509_ASN_ENCODING,
|
| + CRYPT_VERIFY_CERT_SIGN_SUBJECT_CERT,
|
| + reinterpret_cast<void*>(const_cast<PCERT_CONTEXT>(cert_handle)),
|
| + CRYPT_VERIFY_CERT_SIGN_ISSUER_CERT,
|
| + reinterpret_cast<void*>(const_cast<PCERT_CONTEXT>(cert_handle)),
|
| + 0,
|
| + NULL);
|
| +}
|
| +
|
| } // namespace net
|
|
|