mirror of
https://github.com/sudo-project/sudo.git
synced 2025-08-31 06:15:37 +00:00
Initialize sudo_conv and sudo_printf in sudoers_audit_open().
We will need them if there is an error parsing sudoers and leaving them unset can result in NULL deref. Also set the text domain to "sudoers" like we do for the policy and I/O logging open functions. Bug #934.
This commit is contained in:
@@ -135,6 +135,11 @@ sudoers_audit_open(unsigned int version, sudo_conv_t conversation,
|
||||
int ret;
|
||||
debug_decl(sudoers_audit_open, SUDOERS_DEBUG_PLUGIN);
|
||||
|
||||
sudo_conv = conversation;
|
||||
sudo_printf = plugin_printf;
|
||||
|
||||
bindtextdomain("sudoers", LOCALEDIR);
|
||||
|
||||
/* Initialize the debug subsystem. */
|
||||
for (cur = settings; (cp = *cur) != NULL; cur++) {
|
||||
if (strncmp(cp, "debug_flags=", sizeof("debug_flags=") - 1) == 0) {
|
||||
|
Reference in New Issue
Block a user