Commit a10d3906 authored by Martin Sucha's avatar Martin Sucha Committed by Brad Fitzpatrick

crypto/x509: document fields used in CreateCertificate

The added fields are used in buildExtensions so
should be documented too.

Fixes #21363

Change-Id: Ifcc11da5b690327946c2488bcf4c79c60175a339
Reviewed-on: https://go-review.googlesource.com/113916Reviewed-by: default avatarBrad Fitzpatrick <bradfitz@golang.org>
parent 5c8f65b9
...@@ -1952,7 +1952,8 @@ func buildExtensions(template *Certificate, subjectIsEmpty bool, authorityKeyId ...@@ -1952,7 +1952,8 @@ func buildExtensions(template *Certificate, subjectIsEmpty bool, authorityKeyId
} }
// Adding another extension here? Remember to update the maximum number // Adding another extension here? Remember to update the maximum number
// of elements in the make() at the top of the function. // of elements in the make() at the top of the function and the list of
// template fields used in CreateCertificate documentation.
return append(ret[:n], template.ExtraExtensions...), nil return append(ret[:n], template.ExtraExtensions...), nil
} }
...@@ -2043,21 +2044,34 @@ var emptyASN1Subject = []byte{0x30, 0} ...@@ -2043,21 +2044,34 @@ var emptyASN1Subject = []byte{0x30, 0}
// //
// - AuthorityKeyId // - AuthorityKeyId
// - BasicConstraintsValid // - BasicConstraintsValid
// - CRLDistributionPoints
// - DNSNames // - DNSNames
// - EmailAddresses
// - ExcludedDNSDomains // - ExcludedDNSDomains
// - ExcludedEmailAddresses
// - ExcludedIPRanges
// - ExcludedURIDomains
// - ExtKeyUsage // - ExtKeyUsage
// - ExtraExtensions
// - IsCA // - IsCA
// - IssuingCertificateURL
// - KeyUsage // - KeyUsage
// - MaxPathLen // - MaxPathLen
// - MaxPathLenZero // - MaxPathLenZero
// - NotAfter // - NotAfter
// - NotBefore // - NotBefore
// - OCSPServer
// - PermittedDNSDomains // - PermittedDNSDomains
// - PermittedDNSDomainsCritical // - PermittedDNSDomainsCritical
// - PermittedEmailAddresses
// - PermittedIPRanges
// - PermittedURIDomains
// - PolicyIdentifiers
// - SerialNumber // - SerialNumber
// - SignatureAlgorithm // - SignatureAlgorithm
// - Subject // - Subject
// - SubjectKeyId // - SubjectKeyId
// - URIs
// - UnknownExtKeyUsage // - UnknownExtKeyUsage
// //
// The certificate is signed by parent. If parent is equal to template then the // The certificate is signed by parent. If parent is equal to template then the
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment