Bug 1029

Summary: Configuring multiple log servers error
Product: Sudo Reporter: jim.jarocki
Component: Log serverAssignee: Todd C. Miller <Todd.Miller>
Status: RESOLVED INVALID    
Severity: normal    
Priority: low    
Version: 1.9.10   
Hardware: PC   
OS: Linux   

Description jim.jarocki 2022-04-22 12:47:16 MDT
I'm attempting to send sudo logs to 2 servers running sudo-logsrvd.  Getting this error, but according to the man page, this should work:

[jjarocki@ashburn100165 ~]$ sudo su -
/etc/sudoers:76:44: syntax error
Defaults log_servers = 100.76.252.39:30343 100.76.252.31:30343
                                           ^~~~~~~~~~~~~~~~~~~
[sudo] password for jjarocki: 
Last login: Fri Apr 22 18:22:48 UTC 2022 on pts/4
[root@ashburn100165 ~]# 

From visudo:

[root@ashburn100165 sudoers.d]# visudo
/etc/sudoers:76:44: syntax error
Defaults log_servers = 100.76.252.39:30343 100.76.252.31:30343
                                           ^~~~~~~~~~~~~~~~~~~
visudo: /etc/sudoers.tmp unchanged
/etc/sudoers:76:44: syntax error
Defaults log_servers = 100.76.252.39:30343 100.76.252.31:30343
                                           ^~~~~~~~~~~~~~~~~~~
What now? 

Version info:

sudo-1.9.10-1.el7.x86_64.rpm
sudo-logsrvd-1.9.10-1.el7.x86_64.rpm
Comment 1 Todd C. Miller 2022-04-22 12:50:08 MDT
You need to quote whitespace in sudoers.  So either of the following would work:

Defaults log_servers = "100.76.252.39:30343 100.76.252.31:30343"

or:

Defaults log_servers = 100.76.252.39:30343\ 100.76.252.31:30343