Security is one of the tasks most seriously taken by companies, developers and anyone who is in the middle of the systems since, on computers, whether clients or servers, sensitive information such as personnel files is usually hosted , payment, HR, etc., so that unauthorized access can trigger sensitive security risks..
To prevent this, there are hundreds of different mechanisms and one of the oldest and default by all types of equipment is the use of passwords. We know very well from other TechnoWikis tutorials, that we must meet certain criteria for a secure password (combination of letters and numbers, use upper and lower case letters, use symbols, etc.).
Therefore, it is always ideal to take the best measures in this regard. Despite this there is a problem and that is that today we need passwords for everything practically (access to our mail, our mobile, business or educational platforms, etc.) and it is very normal that with so much password in our head we forget some as the password to access the system. In this case we talk about Ubuntu , and this is something a bit delicate because if we do not access the system we will be in serious trouble when working..
We do not recommend at any time suppressing the use of the password, but if only you have access to the computer and are sure that there is no vulnerability today TechnoWikis will explain various methods to log in without having to enter the password.
To keep up, remember to subscribe to our YouTube channel! SUBSCRIBE
1. Make Linux not ask for a password using the terminal
The terminal in Linux is the key point to perform hundreds of administrative and support actions in the system.
Step 1
The first option is to access the terminal and access the sudoers file by executing the following:
sudo visudo
Step 2
We will see the following:
Step 3
There we must locate the section "Members of the admin group may gain root privileges":
Step 4
There we will add the line “NOPASSWD:†before the last ALL as follows:
Step 5
We save the changes using the following key combination. We can verify that no password is required either to log in or to execute orders in the terminal.
+ O Ctrl + O
We leave the editor using:
+ X Ctrl + X
2. Make commands run as root in Linux
Step 1
This objective allows to execute that each command using with sudo is executed with root permissions, for this purpose, being the same file / etc / sudoers, we will locate the line “Allow members of group sudo to execute any comand†and there establish what following:
“User†ALL = (ALL) NOPASSWD: ALL
Step 2
We save the changes with the following keys:
+ O Ctrl + O
3. Make Linux not ask for the password in some commands
The previous method avoids entering the password for all orders, but we can specify only in which commands this privilege will apply, for this we must indicate the path of the desired commands.
Step 1
In the same line “Allow members of group sudo to execute any comand†we will execute, for example, the following:
“User†ALL = (ALL) NOPASSWD: / usr / bin / apt-get, / sbin / shutdown
Step 2
We save the changes with:
+ O Ctrl + O
4. Make Linux not ask for the password with a user
It is possible that in the team we have different users and therefore we want to give that user permission to execute a command without requiring the use of a password, for this, just enter the user and the respective commands in the line “User privilege specification â€:
“User†ALL = / usr / bin / apt-get, / sbin / shutdown
5. Create a Linux user account without a password
Step 1
For this process there are two options, the first is from the terminal either creating a new user or with an existing account, there we must have the root permissions and then execute the following syntax:
sudo passwd -d user
Step 2
The -d (delete) parameter deletes the password of the selected user:
Step 3
This method applies to passwords for both login and command execution, but we can from the moment of the installation of the system prevent the user from entering with a password, for this, we continue with Ubuntu 19, at the time of installation in the section of the creation of the user activate the box "Log in automatically". This will prevent password entry.
With any of the methods described by TechnoWikis it will be possible to avoid using the password, but remember the importance of this in security and privacy issues..