Add log_format sudoers setting to select sudo or json format logs.
Defaults to sudo-format logs.
This commit is contained in:
@@ -38,6 +38,12 @@ static struct def_values def_data_timestamp_type[] = {
|
||||
{ NULL, 0 },
|
||||
};
|
||||
|
||||
static struct def_values def_data_log_format[] = {
|
||||
{ "sudo", sudo },
|
||||
{ "json", json },
|
||||
{ NULL, 0 },
|
||||
};
|
||||
|
||||
struct sudo_defs_types sudo_defs_table[] = {
|
||||
{
|
||||
"syslog", T_LOGFAC|T_BOOL,
|
||||
@@ -559,6 +565,10 @@ struct sudo_defs_types sudo_defs_table[] = {
|
||||
"runchroot", T_STR|T_BOOL|T_CHPATH,
|
||||
N_("Root directory to change to before executing the command: %s"),
|
||||
NULL,
|
||||
}, {
|
||||
"log_format", T_TUPLE,
|
||||
N_("The format of logs to produce: %s"),
|
||||
def_data_log_format,
|
||||
}, {
|
||||
NULL, 0, NULL
|
||||
}
|
||||
|
Reference in New Issue
Block a user