Standard library / crypto/x509
crypto/x509.CANotAuthorizedForThisName
Name constraints reject a name in the leaf. This is an error reason, not a verification option. Expected stdout: '2\n'.
Formal Syntax & Structure
go syntaxgo
const CANotAuthorizedForThisName InvalidReason = 2Working Example
Example Snippetgo
package main
import ( "crypto/x509" "fmt")
func main() { fmt.Println(int(x509.CANotAuthorizedForThisName)) }
func must[T any](v T, e error) T { if e != nil { panic(e) } return v}func check(e error) { if e != nil { panic(e) }}