Linux BACKDOOR: sudo can be changed to root without a password in any account.

Source: Internet
Author: User
Adding a user in Linux is a very difficult task, and it is no longer in the familiar windows interface. I remember that if you want to create a root user in Linux, you need to change its UID to 0, in this way, the root operation can be performed without modifying the root user password. However, if you have experienced a Linux administrator, you should be depressed. You want to add a new

Adding a user in Linux is a very difficult task, and it is no longer in the familiar windows interface. I remember that if you want to create a root user in Linux, you need to change its UID to 0, in this way, the root operation can be performed without modifying the root user password. However, if you have experienced a Linux administrator, you should be depressed. Do you want to add a new user or the UID is 0? Of course, due to the complexity of Linux management, this can still be avoided by many administrators.
To hide users in Linux, you only need to useCommandThat is,"SuDo ", do you still remember the explanation of this command in the system? Sudo allows the user to switch identities without a password. How can this user have The sudo permission? You need to edit the/etc/sudoers file. You can add the following line in the content:

USER ALL=(ALL) NOPASSWD: ALL

This allows the current user to convert to any user and execute any command. Generally, the Administrator will not view the sudo file. Now we have quietly penetrated it.

A brief overview of the actual case: After a website is penetrated, the shell is obtained, the password of the current user is obtained in the database, and the root permission is obtained through overflow, to facilitate the next visit, we modified the/etc/sudoers file and cleared the log and exited.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.