Skip to content

Add lint for checking compliance with §7.1.2.10.5 of the BRs (CA Certificate Policies)#887

Merged
christopher-henderson merged 43 commits intozmap:masterfrom
defacto64:invalid_ca_certificate_policies
Oct 26, 2024
Merged

Add lint for checking compliance with §7.1.2.10.5 of the BRs (CA Certificate Policies)#887
christopher-henderson merged 43 commits intozmap:masterfrom
defacto64:invalid_ca_certificate_policies

Conversation

@defacto64
Copy link
Copy Markdown
Contributor

Please add this lint to verify that a TLS Subordinate CA certificate complies with §7.1.2.10.5 of the BRs (CA Certificate Policies).

In particular, this lint checks that Certificate Policies extension either contains the AnyPolicy OID alone (according to Table 69 in the BRs) or it contains at least one CABF Reserved Policy OID (according to Table 70).

Preliminarily, this lint checks that the CertificatePolicies extension is present, this being a requirement for all TLS Subordinate CAs as prescribed by various sections of Chapter 7 of the BRs. This could be considered a separate check and, as such, it could be moved to a separate lint, but I think it's simpler to leave it in here.

Examples of CA certificates failing this lint can be found at https://bugzilla.mozilla.org/show_bug.cgi?id=1921597

defacto64 and others added 30 commits March 8, 2024 16:07
Added //nolint:all to comment block to avoid golangci-lint to complain about duplicate words in comment
Fine to me.

Co-authored-by: Christopher Henderson <[email protected]>
As per Chris Henderson's suggestion, to "improve readability".
As per Chris Henderson's suggestion.
Added CABFEV_Sec9_2_8_Date
lint.RegisterCertificateLint(&lint.CertificateLint{
LintMetadata: lint.LintMetadata{
Name: "e_invalid_ca_certificate_policies",
Description: "Checks that the Policy OIDs in the CertificatePolicies extension of a SubCA certificate comply with CABF requirements",
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I was going to petition to break this up since the description is kind of a catch-all. But 7.1.2.10.5 really is kinda relatively large and tangled.

@christopher-henderson christopher-henderson merged commit d0dc117 into zmap:master Oct 26, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants