Sign Up
Log In
Log In
or
Sign Up
Places
All Projects
Status Monitor
Collapse sidebar
openSUSE:Step:FrontRunner
sudo.32786
sudo-no-double-free.patch
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File sudo-no-double-free.patch of Package sudo.32786
Fix potential double free for rules that include a CHROOT= option. If a rule with a CHROOT= option matches the user, host and runas, the user_cmnd variable could be freed twice. diff -r 97ae12488007 plugins/sudoers/match_command.c --- a/plugins/sudoers/match_command.c Thu Feb 16 11:45:31 2023 -0700 +++ b/plugins/sudoers/match_command.c Wed Feb 22 13:51:04 2023 -0700 @@ -818,12 +818,16 @@ command_matches(const char *sudoers_cmnd /* Rule-specific runchroot, reset user_cmnd and user_stat. */ int status; + /* Save old user_cmnd first, set_cmnd_path() will free it. */ saved_user_cmnd = user_cmnd; + user_cmnd = NULL; if (user_stat != NULL) saved_user_stat = *user_stat; status = set_cmnd_path(runchroot); - if (status != FOUND) + if (status != FOUND) { + user_cmnd = saved_user_cmnd; saved_user_cmnd = NULL; + } if (info != NULL) info->status = status; }
Locations
Projects
Search
Status Monitor
Help
OpenBuildService.org
Documentation
API Documentation
Code of Conduct
Contact
Support
@OBShq
Terms
openSUSE Build Service is sponsored by
The Open Build Service is an
openSUSE project
.
Sign Up
Log In
Places
Places
All Projects
Status Monitor