cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
1814
Views
0
Helpful
2
Replies

Duo on Ubuntu sudo not working

Browncoat1
Level 1
Level 1

I have setup Duo on Ubuntu 16.04 and got it working successfully. The problem that I have now is that sudo no longer works. I’m prompted for a local password when invoking sudo, and when I enter it, it says it is incorrect (the password is correct). I had confirmed sudo was working correctly before, but now after a power outage, I brought the system back online and I am still able to ssh successfully, but sudo is failing.

2 Replies 2

billchengusc
Level 1
Level 1

Just wondering if you have found a solution for your problem. I’m running Ubuntu 18.04 and I think I have exactly the same problem. After I get duo authentication to work (i.e., I can ssh to my Ubuntu 18.04 system and it will ask for duo authentication), I found out that I cannot run anything with the “sudo” command on that system. It keeps asking for my password and the command is not executed. Any pointer would be appreciated!

I think I’ve found a way to get this to work (not 100% yet). In the PAM Examples section for Ubuntu 18.04 on Duo Unix - 2FA for SSH with PAM Support (pam_duo) | Duo Security, if I don’t make the changes in /etc/pam.d/common-auth, I am able to trigger duo authentication when I ssh to my machine using publickey authentication AND I am also able to use the “sudo” command on my machine (it would prompt me for password). The reason why I said it’s not 100% is because I thought that when I use a “sudo” command, it will prmopt me for password AND will also trigger duo authentication! So, the last step is not happening for me.

Quick Links