Bug 1046

Summary: TSID in syslog isn't complete value
Product: Sudo Reporter: illie <illie_>
Component: SudoAssignee: Todd C. Miller <Todd.Miller>
Status: RESOLVED FIXED    
Severity: normal    
Priority: low    
Version: 1.9.12   
Hardware: PC   
OS: Linux   

Description illie 2023-03-31 14:52:52 MDT
After adding "Defaults log_output" to the sudoers file, the TSID value in syslog is only two characters instead of six.

root@nuc-1:/var/log# grep TSID auth.log
Mar 31 13:34:26 nuc-1 sudo:    illie : TTY=pts/3 ; PWD=/root ; USER=root ; TSID=01 ; COMMAND=/bin/bash
root@nuc-1:/var/log# sudoreplay 01
sudoreplay: /var/log/sudo-io/01: No such file or directory
root@nuc-1:/var/log# sudoreplay -l
Mar 31 13:34:26 2023 : illie : HOST=nuc-1 ; TTY=/dev/pts/3 ; CWD=/home/illie ; USER=root ; TSID=00/00/01 ; COMMAND=/bin/bash
root@nuc-1:/var/log#

This works as expected in 1.8.31p1 but is broken in 1.9.x (tested both 1.9.9 and 1.9.13p3)
Comment 1 Todd C. Miller 2023-03-31 15:51:56 MDT
Thanks for the report, this is fixed by https://www.sudo.ws/repos/sudo/rev/f272de885273
Comment 2 Todd C. Miller 2023-06-27 17:27:13 MDT
Fixed in sudo 1.9.14.