PDA

View Full Version : [SOLVED] Cannot cancel sudo password request with a single Ctrl-C



MacUntu
April 16th, 2010, 12:54 PM
Pretty weird: I cannot abort a sudo password request (gnome-terminal and VT) with a single Ctrl-C key combo. Instead the request is shown again and if I push Ctrl-C again or use the enter key I'm back to the prompt:


test@box:~$ sudo echo "foo"
[sudo] password for test: // Ctrl-C
[sudo] password for test: // Ctrl-C or Enter
test@box:~$

I can reproduce this with a second machine I've used during the Lucid dev cycle but I can't with a daily live CD (changed sudoers to ask for a pwd), so maybe some upgrade-voodoo has jinxed my machines. :-k

Any ideas where I should dig to find the root of all evil? It's definitely not the sudo package.

MacUntu
April 16th, 2010, 04:37 PM
FWIF, directly sending SIGINT to the sudo process has the same effect.

Am I really alone with this?

coffeecat
April 16th, 2010, 04:54 PM
Am I really alone with this?

No. I can confirm the same here. Haven't a clue why though.

cariboo907
April 16th, 2010, 05:08 PM
When I try to run your command, copy and pasted from the post, I get:


sudo echo "Oachkatzlschwoaf!"
bash: !": event not found

Bachstelze
April 16th, 2010, 05:10 PM
When I try to run your command, copy and pasted from the post, I get:


sudo echo "Oachkatzlschwoaf!"
bash: !": event not found

This was obviously a bogus command...

MacUntu
April 16th, 2010, 05:13 PM
Oooops, sorry!

Edit:

So, after a bit of thinking I found something in /etc/pam.d/common-auth:

Weird behavior:

auth [success=2 default=ignore] pam_unix.so nullok_secure
auth [success=1 default=ignore] pam_winbind.so krb5_auth krb5_ccache_type=FILE cached_login try_first_pass
auth requisite pam_deny.so
auth required pam_permit.so

Expected behavior:

auth [success=1 default=ignore] pam_unix.so nullok_secure
auth requisite pam_deny.so
auth required pam_permit.so

MacUntu
April 16th, 2010, 05:35 PM
Ok, this is caused by installing winbind, will open a bug report.

Bug report: https://bugs.launchpad.net/ubuntu/+source/samba/+bug/564842