LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   Cant save password authorization (https://www.linuxquestions.org/questions/linux-newbie-8/cant-save-password-authorization-4175507157/)

Adol 06-05-2014 02:08 PM

Cant save password authorization
 
Hello,

Im using a vpn through network manager and I want to start it on startup of KDE. I already have a plan of using a bash script and using:
Code:

nmcli con up id (name of connection)
This works.

The problem is that even though I click on save authorization, it asks me for my root password every time I try to start the VPN. I understand that this can be very useful for security reasons, but this is a home system and I am really not concerned with that.

Is there a way I can stop the check for authorization for network manager?

I do not want authorization for everything to stop. I still want the root password security to continue for other things on the system.

Thanks in advance.

casualfred 06-06-2014 09:22 PM

Hello Adol, there is indeed a way to allow a user to run a command with root privileges without a password by editing your sudoers file. First, run in a shell as root:
Code:

# visudo
This will allow you to edit the sudoers file using vi. If you wanted to run nmcli as root, and if your user name is adol, and if nmcli is located in /usr/bin, you would add a line like this to the sudoers file:
Code:

adol ALL=(ALL) NOPASSWD:/usr/bin/nmcli
Hopefully that would fix it.


All times are GMT -5. The time now is 10:29 AM.