Add support for "accept" audit events sent by the sudo front-end.
With this change, the sudo front-end will send an "accept" audit event to the audit plugins after all the I/O logging plugins have been initialized. This can be used by an audit plugin that does not care about the result of the individual policy and approval plugins and only wants to receive a single "accept" event if all policy and approval plugins have succeeded. The plugin_type argument for events sent by the front-end is SUDO_FRONT_END (0).
This commit is contained in:
@@ -282,6 +282,10 @@ main(int argc, char *argv[], char *envp[])
|
||||
iolog_open(settings, user_info, command_info, nargc, nargv,
|
||||
user_env_out);
|
||||
|
||||
/* Audit the accept event on behalf of the sudo front-end. */
|
||||
audit_accept("sudo", SUDO_FRONT_END, command_info,
|
||||
nargv, user_env_out);
|
||||
|
||||
/* Setup command details and run command/edit. */
|
||||
command_info_to_details(command_info, &command_details);
|
||||
command_details.tty = user_details.tty;
|
||||
|
Reference in New Issue
Block a user