1
/**************************************************************************
2
*** COPYRIGHT (c) 2002 by TransNexus, Inc. ***
4
*** This software is property of TransNexus, Inc. ***
5
*** This software is freely available under license from TransNexus. ***
6
*** The license terms and conditions for free use of this software by ***
7
*** third parties are defined in the OSP Toolkit Software License ***
8
*** Agreement (LICENSE.txt). Any use of this software by third ***
9
*** parties, which does not comply with the terms and conditions of the ***
10
*** OSP Toolkit Software License Agreement is prohibited without ***
11
*** the prior, express, written consent of TransNexus, Inc. ***
13
*** Thank you for using the OSP ToolKit(TM). Please report any bugs, ***
14
*** suggestions or feedback to support@transnexus.com ***
16
**************************************************************************/
24
#define OSPC_ERR_ENROLL 24000
26
/* Errors generated when there's something syntactically wrong
27
* with the inputs ( such as how they were entered, their length,
29
#define OSPC_ERR_ENROLL_PARAMS_FUNCTION (OSPC_ERR_ENROLL + 10)
30
#define OSPC_ERR_ENROLL_PARAMS_USERNAME (OSPC_ERR_ENROLL + 11)
31
#define OSPC_ERR_ENROLL_PARAMS_PASSWORD (OSPC_ERR_ENROLL + 12)
32
#define OSPC_ERR_ENROLL_PARAMS_DEVICEID (OSPC_ERR_ENROLL + 13)
33
#define OSPC_ERR_ENROLL_PARAMS_CUSTOMERID (OSPC_ERR_ENROLL + 14)
34
#define OSPC_ERR_ENROLL_PARAMS_SSL_URL (OSPC_ERR_ENROLL + 15)
35
#define OSPC_ERR_ENROLL_PARAMS_CA_URL (OSPC_ERR_ENROLL + 16)
36
#define OSPC_ERR_ENROLL_PARAMS_CACERT (OSPC_ERR_ENROLL + 17)
37
#define OSPC_ERR_ENROLL_PARAMS_CERTREQ (OSPC_ERR_ENROLL + 18)
38
#define OSPC_ERR_ENROLL_PARAMS_CA_FPRINT (OSPC_ERR_ENROLL + 19)
40
/* Errors generated when there's something semantically
41
* wrong with the inputs ( such as the wrong datatype, etc. )
43
#define OSPC_ERR_ENROLL_BAD_USERNAME (OSPC_ERR_ENROLL + 30)
44
#define OSPC_ERR_ENROLL_BAD_PASSWORD (OSPC_ERR_ENROLL + 31)
45
#define OSPC_ERR_ENROLL_BAD_DEVICE_ID (OSPC_ERR_ENROLL + 32)
46
#define OSPC_ERR_ENROLL_BAD_CUSTOMER_ID (OSPC_ERR_ENROLL + 33)
47
#define OSPC_ERR_ENROLL_BAD_CERT_B64 (OSPC_ERR_ENROLL + 34)
48
#define OSPC_ERR_ENROLL_BAD_CERT (OSPC_ERR_ENROLL + 35)
49
#define OSPC_ERR_ENROLL_BAD_CERT_REQ (OSPC_ERR_ENROLL + 36)
50
#define OSPC_ERR_ENROLL_BAD_FPRINT (OSPC_ERR_ENROLL + 37)
52
/* Errors generated when parameters are invalid: */
53
#define OSPC_ERR_ENROLL_INVALID_ARG (OSPC_ERR_ENROLL + 40)
54
#define OSPC_ERR_ENROLL_NO_MEMORY (OSPC_ERR_ENROLL + 41)
55
#define OSPC_ERR_ENROLL_NULL_PTR (OSPC_ERR_ENROLL + 42)
57
/* Errors generated while creating a nonce: */
58
#define OSPC_ERR_ENROLL_CREATE_NONCE_BAD_PARAMS (OSPC_ERR_ENROLL + 50)
59
#define OSPC_ERR_ENROLL_GEN_NONCE (OSPC_ERR_ENROLL + 51)
61
/* String-related errors: */
62
#define OSPC_ERR_BAD_ALNUM_STR (OSPC_ERR_ENROLL + 60)
63
#define OSPC_ERR_BAD_ASCII_STR (OSPC_ERR_ENROLL + 61)
64
#define OSPC_ERR_ENROLL_BAD_DIGIT_STR (OSPC_ERR_ENROLL + 62)
66
/* Errors related to finding names and values within strings: */
67
#define OSPC_ERR_ENROLL_VALUE_NOT_FOUND (OSPC_ERR_ENROLL + 70)
68
#define OSPC_ERR_ENROLL_SEARCH_FIELD_NOT_FOUND (OSPC_ERR_ENROLL + 71)
70
/* Errors related to constructing enrollment requests: */
71
#define OSPC_ERR_ENROLL_INVALID_REQUEST_PARAMS (OSPC_ERR_ENROLL + 80)
72
#define OSPC_ERR_ENROLL_CREATE_REQUEST_BODY (OSPC_ERR_ENROLL + 81)
73
#define OSPC_ERR_ENROLL_INVALID_RESPONSE (OSPC_ERR_ENROLL + 82)
75
/* Errors related to ASN1 comparison and parsing functionality: */
76
#define OSPC_ERR_ENROLL_ASN1_CMP_LENGTH_MISMATCH (OSPC_ERR_ENROLL + 90)
77
#define OSPC_ERR_ENROLL_ASN1_CMP_MISMATCH (OSPC_ERR_ENROLL + 91)
78
#define OSPC_ERR_ENROLL_ASN1_PARSE (OSPC_ERR_ENROLL + 92)
80
/* Errors related to appending name-value pairs, copying strings, and
81
* other miscellaneous convenience functions:
83
#define OSPC_ERR_ENROLL_APPENDING_NAME_VALUE_PAIR (OSPC_ERR_ENROLL + 100)
84
#define OSPC_ERR_ENROLL_SOURCE_STRING_EMPTY (OSPC_ERR_ENROLL + 101)