doc.go 1.3 KB

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