Liberator Auth API  7.1.15.30043-c7cb7c0
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 Sun Aug 16 2020 12:52:49 for Liberator Auth API