1

I am new to Linux systems, so please bear with me.

I wanted to remove the need to enter my password when using sudo and logging into the computer, so I changed the sudoers.d directory using sudo visudo and adding NOPASSWD:ALL to root, admin, and sudo.

Then I deleted my username password using sudo passwd -d username. (replacing username with actual username)

However, now that I do not have a password associated with my username, I am now unable to install software through Ubuntu Software because it asks for authentication, even when I have no password associated with my username.

I tried to turn off this feature using a solution from a 9-year-old post on this forum, but after changing auth_admin and auth_admin_keep to yes under the org.debian.apt.install-or-remove-packages part of /usr/share/polkit-1/actions/org.debian.apt.policy, nothing has changed. Ubuntu Software still asks for authentication...

1 Answers1

0

It seemsorg.debian.apt.policy is not relevant for the Ubuntu Software Center anymore. In the same directory (/usr/share/polkit-1/actions/ ) you'll find the file io.snapcraft.snapd.policy, which is relevant for snap packages. In the file find the line:

<action id="io.snapcraft.snapd.manage">

under that line change

<allow_active>auth_admin_keep</allow_active>

to

<allow_active>yes</allow_active>.

Another file in the same directory you'll need to edit is org.freedesktop.packagekit.policy in order to install packages via apt. In this file you'll find the following "action ids":

<action id="org.freedesktop.packagekit.cancel-foreign"> <action id="org.freedesktop.packagekit.package-install"> <action id="org.freedesktop.packagekit.package-install-untrusted"> <action id="org.freedesktop.packagekit.package-reinstall"> <action id="org.freedesktop.packagekit.package-downgrade"> <action id="org.freedesktop.packagekit.system-trust-signing-key"> <action id="org.freedesktop.packagekit.package-eula-accept"> <action id="org.freedesktop.packagekit.package-remove"> <action id="org.freedesktop.packagekit.system-update"> <action id="org.freedesktop.packagekit.system-sources-configure"> <action id="org.freedesktop.packagekit.system-sources-refresh"> <action id="org.freedesktop.packagekit.system-network-proxy-configure"> <action id="org.freedesktop.packagekit.device-rebind"> <action id="org.freedesktop.packagekit.upgrade-system"> <action id="org.freedesktop.packagekit.repair-system"> <action id="org.freedesktop.packagekit.trigger-offline-update"> <action id="org.freedesktop.packagekit.trigger-offline-upgrade"> <action id="org.freedesktop.packagekit.clear-offline-update">

Underneath the associated description and message tags change the line:

<allow_active>auth_admin_keep</allow_active> or <allow_active>auth_admin</allow_active>

to

<allow_active>yes</allow_active>

After these changes you'll be able to use the Ubuntu Software Center without authenticating. You might have to reboot first.

However it is not recommended to use Ubuntu without sudo authentication.

Kind regards, Jeroen.

jeroen
  • 1,980