2
0
mirror of https://github.com/sudo-project/sudo.git synced 2025-08-31 14:25:15 +00:00

Disable fast_glob and fdexec if SUDOERS_NAME_MATCH is defined.

We use SUDOERS_NAME_MATCH for fuzzing when we want to avoid searching
the file system for commands.
This commit is contained in:
Todd C. Miller
2023-08-28 13:18:37 -06:00
parent c858acc481
commit 07003d9020

View File

@@ -510,6 +510,12 @@ init_defaults(void)
#endif
#ifdef UMASK_OVERRIDE
def_umask_override = true;
#endif
#ifdef SUDOERS_NAME_MATCH
def_fast_glob = true;
def_fdexec = never;
#else
def_fdexec = digest_only;
#endif
def_timestamp_type = TIMESTAMP_TYPE;
if ((def_iolog_file = strdup("%{seq}")) == NULL)
@@ -554,7 +560,6 @@ init_defaults(void)
def_netgroup_tuple = false;
def_sudoedit_checkdir = true;
def_iolog_mode = S_IRUSR|S_IWUSR;
def_fdexec = digest_only;
def_log_allowed = true;
def_log_denied = true;
def_log_format = sudo;