using the super user tab breaks /etc/sudoers
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
smb4k (Ubuntu) |
Fix Released
|
High
|
Unassigned |
Bug Description
Binary package hint: smb4k
Before, my /etc/sudoers file looks like this:
root@batou:/etc# cat sudoers.before
# /etc/sudoers
#
# This file MUST be edited with the 'visudo' command as root.
#
# See the man page for details on how to write a sudoers file.
# Defaults
Defaults !lecture,
# Uncomment to allow members of group sudo to not need a password
# %sudo ALL=NOPASSWD: ALL
# Host alias specification
# User alias specification
# Cmnd alias specification
# User privilege specification
root ALL=(ALL) ALL
# Members of the admin group may gain root privileges
%admin ALL=(ALL) ALL
If I configure smb4k to use sudo and it edits the file, it looks like this:
root@batou:/etc# cat sudoers.after
passprompt
# /etc/sudoers
#
# This file MUST be edited with the 'visudo' command as root.
#
# See the man page for details on how to write a sudoers file.
# Defaults
Defaults !lecture,
# Uncomment to allow members of group sudo to not need a password
# %sudo ALL=NOPASSWD: ALL
# Host alias specification
# User alias specification
# Cmnd alias specification
# User privilege specification
root ALL=(ALL) ALL
# Members of the admin group may gain root privileges
%admin ALL=(ALL) ALL
# Entries for Smb4K users.
# Generated by Smb4K. Please do not modify!
User_Alias SMB4KUSERS = randall
Defaults:SMB4KUSERS env_keep += "PASSWD USER"
SMB4KUSERS batou = NOPASSWD: /usr/bin/smb4k_kill
SMB4KUSERS batou = NOPASSWD: /usr/bin/
SMB4KUSERS batou = NOPASSWD: /usr/bin/
# End of Smb4K user entries.
Note the first line being "passprompt" which is not a valid /etc/sudoers line, and will break various other apps on an Ubuntu system. But even commenting out that line will make smb4k still unusable, as it won't mount smb shares.
I just noticed that if you type in the wrong password, following lines will show up at the top of /etc/sudoers ...
passprompt
Sorry, try again.
passprompt
Sorry, try again.
passprompt
# /etc/sudoers
#
Obviously this one is a no-go as this will render the system unusable. People won't be able to start a package manager or even use sudo to edit the /etc/sudoers file back!
If you need any help with reproducing this bug on your system, just send me a mail and we'll work it out.
Kind regards,
Lee
Which version of Ubuntu and smb4k are you using? Please also give us reproduction instructions in this bug.