Skip to content

tlsx detects valid root certificates from Sectigo as untrusted #882

@n-gbr

Description

@n-gbr

tlsx version: v1.2.2

Current Behavior:

When scanning a domain using Nuclei’s ssl/untrusted-root-certificate.yaml template, tlsx is used internally to determine whether the root certificate is trusted.

tlsx considers a CA untrusted, if it is:

  • a CA certificate
  • self-signed
  • not present in assets/root-certs.pem

The according logic is implemented here:

// IsUntrustedCA returns true if the certificate is a self-signed CA
func IsUntrustedCA(certs []*x509.Certificate) bool {
for _, c := range certs {
if c != nil && c.IsCA && IsSelfSigned(c.AuthorityKeyId, c.SubjectKeyId, c.DNSNames) && !assets.IsRootCert(c) {
return true
}
}
return false
}

Problem

Several valid Sectigo root certificates are not included in assets/root-certs.pem and are therefore treated as "untrusted". This leads to Nuclei returning false positives for legitimate, wide used certificates.

Expected Behavior:

Valid root certificates (including Sectigo) should be recognized as trusted (and included in assets/root-certs.pem).

Steps To Reproduce:

  1. Run nuclei -t ssl/untrusted-root-certificate.yaml -u www.example.com:443 --debug
  2. Use a domain whose certificate chain is rooted in Sectigo
  3. Check results to see that the template reports an untrusted root certificate

Metadata

Metadata

Assignees

Labels

Type: BugInconsistencies or issues which will cause an issue or problem for users or implementors.

Type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions