github.com/hellobchain/third_party@v0.0.0-20230331131523-deb0478a2e52/cloudflare/cfssl/errors/doc.go (about)

     1  /*
     2  Package errors provides error types returned in CF SSL.
     3  
     4  1. Type Error is intended for errors produced by CF SSL packages.
     5  It formats to a json object that consists of an error message and a 4-digit code for error reasoning.
     6  
     7  Example: {"code":1002, "message": "Failed to decode certificate"}
     8  
     9  The index of codes are listed below:
    10  	1XXX: CertificateError
    11  	    1000: Unknown
    12  	    1001: ReadFailed
    13  	    1002: DecodeFailed
    14  	    1003: ParseFailed
    15  	    1100: SelfSigned
    16  	    12XX: VerifyFailed
    17  	        121X: CertificateInvalid
    18  	            1210: NotAuthorizedToSign
    19  	            1211: Expired
    20  	            1212: CANotAuthorizedForThisName
    21  	            1213: TooManyIntermediates
    22  	            1214: IncompatibleUsage
    23  	        1220: UnknownAuthority
    24  	2XXX: PrivatekeyError
    25  	    2000: Unknown
    26  	    2001: ReadFailed
    27  	    2002: DecodeFailed
    28  	    2003: ParseFailed
    29  	    2100: Encrypted
    30  	    2200: NotRSA
    31  	    2300: KeyMismatch
    32  	    2400: GenerationFailed
    33  	    2500: Unavailable
    34  	3XXX: IntermediatesError
    35  	4XXX: RootError
    36  	5XXX: PolicyError
    37  	    5100: NoKeyUsages
    38  	    5200: InvalidPolicy
    39  	    5300: InvalidRequest
    40  	    5400: UnknownProfile
    41  	    6XXX: DialError
    42  
    43  2. Type HttpError is intended for CF SSL API to consume. It contains a HTTP status code that will be read and returned
    44  by the API server.
    45  */
    46  package errors