Bug 396 - Error message unrelated to cause
Error message unrelated to cause
Status: RESOLVED WORKSFORME
Product: Sudo
Classification: Unclassified
Component: Sudo
1.6.9
PC Linux
: low low
Assigned To: Todd C. Miller
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2010-03-05 09:51 MST by Zordrak
Modified: 2011-03-03 09:56 MST (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Zordrak 2010-03-05 09:51:11 MST
When the setting "requiretty" blocks an attempt to use sudo without a tty, the error message is "sudo: must be setuid root\n".

This error is unrelated to the cause which is a permission failure as configured in sudoers.

It would be very useful for troubleshooting if sudo gave an error advising why permission was denied rather than the red herring setuid message.
Comment 1 Todd C. Miller 2010-03-05 10:58:58 MST
That error message is only printed when the effective uid of the process is non-zero; it has nothing whatsoever to do with requiretty.
Comment 2 Zordrak 2010-03-08 05:16:47 MST
Regardless of the intent, my point is that if requiretty is invoked, this is the error message that is provided. Can this not be caught elsewise and error before hitting the non-zero error?
Comment 3 Todd C. Miller 2011-03-03 09:56:33 MST
Unable to reproduce in sudo 1.7.5 or 1.8.0.