[sudo-commits] sudo changeset 14938:42838100b526

Todd C. Miller Todd.Miller at sudo.ws
Wed Jul 26 19:44:18 MDT 2023


changeset:	14938:42838100b526 in /raid/repos/sudo
details:	https://www.sudo.ws/repos/sudo/rev/42838100b526
user:		Todd C. Miller <Todd.Miller at sudo.ws>
date:		Wed Jul 26 19:43:49 2023 -0600

Log Message:
	Don't assume that if std{in,out,err} is a tty, it is the user's tty.

	Previously, sudo only checked that the fd was a terminal, not that
	it matched sudo's idea of the user's terminal.  This matters when
	input or output is redirected to a different terminal.  In that
	case we want to interpose the fd with a pipe even if it refers to
	a terminal.  Bug #1056.

diffstat:

 src/exec.c       |  22 ++++++++++++++++++++++
 src/exec_nopty.c |  25 ++++++++++++++-----------
 src/exec_pty.c   |  37 ++++++++++++++++++++-----------------
 src/sudo_exec.h  |   2 ++
 4 files changed, 58 insertions(+), 28 deletions(-)



More information about the sudo-commits mailing list