Describe the bug
While working on #1591, I identified that sudo-rs behavior in PAM conversations without /dev/tty diverges from upstream sudo in both fallback selection and user-facing diagnostics.
In no-tty/headless scenarios, sudo-rs could fail or provide less actionable diagnostics where sudo still follows valid fallback paths.
This affects:
To Reproduce
ssh localhost sudo id
SUDO_ASKPASS=/bin/askpass sudo true </dev/null
Expected behavior
sudo-rs should match sudo behavior for no-tty conversation handling and provide actionable, context-aware error messages.
Describe the bug
While working on #1591, I identified that sudo-rs behavior in PAM conversations without
/dev/ttydiverges from upstream sudo in both fallback selection and user-facing diagnostics.In no-tty/headless scenarios, sudo-rs could fail or provide less actionable diagnostics where sudo still follows valid fallback paths.
This affects:
To Reproduce
Expected behavior
sudo-rs should match sudo behavior for no-tty conversation handling and provide actionable, context-aware error messages.