/**
* \name Return Codes
* exported by the foundation API.
- * result codes begin with the start error code and extend into negative direction.
+ * result codes beginning with negative codes indicate an error.
* @{
*/
-/*! \brief indicating the result of the one specific API is successful or access is allowed */
-#define CYNARA_API_SUCCESS 0
+/*! \brief indicating access that was checked is allowed */
+#define CYNARA_API_ACCESS_ALLOWED 2
/*! \brief indicating that access that was checked is denied */
-#define CYNARA_API_ACCESS_DENIED -1
+#define CYNARA_API_ACCESS_DENIED 1
+
+/*! \brief indicating the result of the one specific API is successful */
+#define CYNARA_API_SUCCESS 0
/*! \brief indicating system is running out of memory state */
-#define CYNARA_API_OUT_OF_MEMORY -2
+#define CYNARA_API_OUT_OF_MEMORY -1
/*! \brief indicating the API's parameter is malformed */
-#define CYNARA_API_INVALID_PARAM -3
+#define CYNARA_API_INVALID_PARAM -2
/*! \brief service not available */
-#define CYNARA_API_SERVICE_NOT_AVAILABLE -4
+#define CYNARA_API_SERVICE_NOT_AVAILABLE -3
/*! \brief indicating that value is not present in cache */
-#define CYNARA_API_CACHE_MISS -5
+#define CYNARA_API_CACHE_MISS -4
/*! \brief indicating that provided method is not supported by library */
-#define CYNARA_API_METHOD_NOT_SUPPORTED -6
+#define CYNARA_API_METHOD_NOT_SUPPORTED -5
/*! \brief indicating an unknown error */
-#define CYNARA_API_UNKNOWN_ERROR -7
+#define CYNARA_API_UNKNOWN_ERROR -6
/** @}*/
#endif // CYNARA_CLIENT_ERROR_H
* \param[in] user User running client.
* \param[in] privilege Privilege that is a subject of a check..
*
- * \return CYNARA_API_SUCCESS on success (access granted), CYNARA_API_ACCESS_DENIED on access denial
+ * \return CYNARA_API_ACCESS_ALLOWED on access allowed, CYNARA_API_ACCESS_DENIED on access denial
* or other error code on error.
*/
int cynara_check(cynara *p_cynara, const char *client, const char *client_session, const char *user,