- /* only same uid (or root client) */
- if (sectoken.val[0] && sectoken.val[0] != server_uid) {
- log("Server create: \"%s\": invalid security token (%d != %d)",
- server_cmd, sectoken.val[0], server_uid);
+ /* get the identity of the requestor and set up audit_info of server */
+ audit_token_to_au32(client_audit_token,
+ &audit_info.ai_auid,
+ &client_euid,
+ NULL /* egid */,
+ NULL /* ruid */,
+ NULL /* rgid */,
+ NULL /* pid */,
+ &audit_info.ai_asid,
+ &audit_info.ai_termid);
+
+ if (client_euid != 0 && client_euid != server_uid) {
+ notice("Server create: \"%s\": insufficient privilege for specified uid (euid-%d != requested-%d)",
+ server_cmd, client_euid, server_uid);