Fix incorrect defines.

pull/139/head
Roger A. Light 10 years ago
parent 2078b6381a
commit f5f5d3885d

@ -38,18 +38,18 @@ struct mosquitto_auth_opt {
*
* Authentication plugins can implement one or both of authentication and
* access control. If your plugin does not wish to handle either of
* authentication or access control it should return MOSQ_ERR_DEFER. In this
* case, the next plugin will handle it. If all plugins return MOSQ_ERR_DEFER,
* the request will be denied.
* authentication or access control it should return MOSQ_ERR_PLUGIN_DEFER. In
* this case, the next plugin will handle it. If all plugins return
* MOSQ_ERR_PLUGIN_DEFER, the request will be denied.
*
* For each check, the following flow happens:
*
* * First plugin does the check, if it returns anything other than
* MOSQ_ERR_DEFER, then the check returns immediately. If the plugin returns
* MOSQ_ERR_DEFER then the next plugin runs its check.
* * If the final plugin returns MOSQ_ERR_DEFER, then the default password file
* and/or acl file check will be made if they are specified in the config
* file.
* MOSQ_ERR_PLUGIN_DEFER, then the check returns immediately. If the plugin
* returns MOSQ_ERR_PLUGIN_DEFER then the next plugin runs its check.
* * If the final plugin returns MOSQ_ERR_PLUGIN_DEFER, then the default
* password file and/or acl file check will be made if they are specified in
* the config file.
* * If plugins are defined and the password file and/or acl file are not
* specified, then the request will be denied.
*/
@ -204,7 +204,7 @@ int mosquitto_auth_security_cleanup(void *user_data, struct mosquitto_auth_opt *
* MOSQ_ERR_SUCCESS if access was granted.
* MOSQ_ERR_ACL_DENIED if access was not granted.
* MOSQ_ERR_UNKNOWN for an application specific error.
* MOSQ_ERR_DEFER if your plugin does not wish to handle this check.
* MOSQ_ERR_PLUGIN_DEFER if your plugin does not wish to handle this check.
*/
int mosquitto_auth_acl_check(void *user_data, const char *clientid, const char *username, const char *topic, int access);
@ -217,7 +217,7 @@ int mosquitto_auth_acl_check(void *user_data, const char *clientid, const char *
* MOSQ_ERR_SUCCESS if the user is authenticated.
* MOSQ_ERR_AUTH if authentication failed.
* MOSQ_ERR_UNKNOWN for an application specific error.
* MOSQ_ERR_DEFER if your plugin does not wish to handle this check.
* MOSQ_ERR_PLUGIN_DEFER if your plugin does not wish to handle this check.
*/
int mosquitto_auth_unpwd_check(void *user_data, const char *username, const char *password);
@ -241,7 +241,7 @@ int mosquitto_auth_unpwd_check(void *user_data, const char *username, const char
* Return value:
* Return 0 on success.
* Return >0 on failure.
* Return MOSQ_ERR_DEFER if your plugin does not wish to handle this check.
* Return MOSQ_ERR_PLUGIN_DEFER if your plugin does not wish to handle this check.
*/
int mosquitto_auth_psk_key_get(void *user_data, const char *hint, const char *identity, char *key, int max_key_len);

@ -46,16 +46,16 @@ int mosquitto_auth_security_cleanup(void *user_data, struct mosquitto_auth_opt *
int mosquitto_auth_acl_check(void *user_data, const char *clientid, const char *username, const char *topic, int access)
{
return MOSQ_ERR_DEFER;
return MOSQ_ERR_PLUGIN_DEFER;
}
int mosquitto_auth_unpwd_check(void *user_data, const char *username, const char *password)
{
return MOSQ_ERR_DEFER;
return MOSQ_ERR_PLUGIN_DEFER;
}
int mosquitto_auth_psk_key_get(void *user_data, const char *hint, const char *identity, char *key, int max_key_len)
{
return MOSQ_ERR_DEFER;
return MOSQ_ERR_PLUGIN_DEFER;
}

Loading…
Cancel
Save