Liberator Auth API  7.1.13.29687-ca4d64a
content.c

A simple example that permissions objects based on the presence of field number 1. In reality, the content of field 1 would normally checked for valid content.

int auth_check_read(session_t *session, object_t *obj)
{
char buffer[1024];
char *val;
if ( obj->type == UNKNOWN_TYPE ) {
return AUTH_AGAIN;
}
if ( ( object_get_value(obj,1,buffer,sizeof(buffer)) ) == NULL ) {
return AUTH_DENY;
}
return AUTH_OK;
}

Generated on Wed Apr 29 2020 16:49:51 for Liberator Auth API