Linux Basics: How to Sudo in Linux without Password

Поділитися
Вставка
  • Опубліковано 14 вер 2024
  • Author: Jeremy Druin
    Twitter: @webpwnized
    Thank you for watching. Please help! Up vote, subscribe or even support this channel at / webpwnized (Click Support).
    This demo on Ubuntu Linux shows how to configure sudo so the user does not have to type in their password to run sudo commands. The simple demo uses visudo available on most popular Linux distributions so this technique will work on many distributions. Ubuntu is not special in this case. Other Linux distributions where this was tested include Debian Linux and Kali Linux, but should work similarly on RedHat distributions like CentOS.
    The password feature on sudo is there by default for safety and security reasons, so it is assumed anyone watching this video understands these security concerns and the consequences of not having password protection on the sudo command.
    Welcome to our comprehensive guide on how to configure and use the "sudo" command in Linux without requiring a password entry. In this tutorial, we'll walk you through the steps to grant users passwordless sudo access, simplifying and streamlining your Linux system administration tasks.
    Video Highlights:
    Introduction to passwordless sudo in Linux
    Understanding the "sudo" command and its significance
    Safely editing the sudoers file
    Enabling passwordless sudo access for specific users
    Testing passwordless sudo privileges
    Best practices for maintaining security
    By the end of this video, you'll be equipped with the knowledge and skills to configure your Linux system to allow specific users to run privileged commands without the need to enter a password each time. This can be incredibly useful for automation, scripting, and managing your Linux server efficiently.
    If you found this tutorial helpful, please consider giving it a thumbs up, subscribing to our channel, and clicking the notification bell to stay updated with our latest Linux tutorials and tech tips.
    Have questions or need further assistance? Feel free to leave a comment, and we'll be happy to help. Share this video with your fellow Linux enthusiasts and system administrators who may benefit from this valuable information.
    Thank you for watching, and let's dive into the world of passwordless "sudo" in Linux!
    #Linux #Sudo #SystemAdministration #PasswordlessSudo #LinuxSecurity #LinuxCommands #TechTutorials #LinuxTips #RootAccess #LinuxPrivileges
    The webpwnized UA-cam channel is dedicated to information security, security testing and ethical hacking. There is an emphasis on web application security but many other topics are covers. Some of these include forensics, network security, security testing tools and security testing processes. The channel provides videos to encourage software developers and system administrators to perform security testing. Also, the channel educates the next generation of security testers and bug bounty hunters who want to respectfully, legally and ethically help system owners that allow security testing.
    Linux sudo command
    Sudo without password
    Run commands without sudo password
    Passwordless sudo in Linux
    Elevate privileges in Linux
    Superuser access in Linux
    Secure sudo configuration
    Disable sudo password prompt
    NOPASSWD directive in sudoers
    Linux system administration
    User management in Linux
    Configure sudoers file
    Root access in Linux
    Linux security tips
    Linux command-line tutorials
    Passwordless authentication in Linux
    Sudoers file editing
    Linux permissions and privileges
    Secure user accounts in Linux
    Linux security best practices

КОМЕНТАРІ • 57

  • @webpwnized
    @webpwnized  7 років тому +7

    Thank you for watching. Please help! Up vote, subscribe or even support this channel at ua-cam.com/users/webpwnized (Click Support).

  • @henryjones1998
    @henryjones1998 Рік тому +3

    Thank you, the best bit was you showing/explaining how to save and exit. Mate, that was a laptop saver, thanks again.

  • @ayeshazakria2215
    @ayeshazakria2215 3 роки тому +5

    what you entered at 1:20
    i mean which password for visudu.
    mine is not working same as of you

  • @butidipeere1258
    @butidipeere1258 4 роки тому +4

    Straight forward, thank you sir. I have a challenge though, after inserting the sudo command, I press 'Enter', after this my key boards just ceases to function (I cannot enter my password)... please help.
    (I'm using version 20.04)

    • @kostisk
      @kostisk 3 роки тому +1

      the password is typed but cannot be seen

  • @bubbiesocutie
    @bubbiesocutie 7 років тому +2

    what if the changes are saved
    but not taking effect :(

  • @canuck2025
    @canuck2025 2 роки тому +1

    I actually want Sudo to ask for my password but don't know how to make it do it

  • @marsamuk
    @marsamuk Рік тому

    Hi. I have an Oracle Linux server that’s joined to an Active Directory domain. I want to grant a specific Active Directory group the ability to switch to the oracle user without entering a password using the su - oracle command. How can I achieve this? Could you provide an example for configuring the sudoers file correctly to allow members of this group to execute the command without a password prompt?
    Thank you for your guidance.

  • @SagarKumar-qn5tt
    @SagarKumar-qn5tt 6 років тому +4

    I am not able to write password in my terminal .
    Please help me sir

    • @SahilTheExplorer
      @SahilTheExplorer 6 років тому +7

      Just write the password and hit enter.. Thank me later

    • @ai639
      @ai639 5 років тому

      @@SahilTheExplorer thx

    • @saara7932
      @saara7932 5 років тому

      Help me sir is The type of disstress i am also in with this problem

    • @cycloprunner5030
      @cycloprunner5030 4 роки тому

      first press enter n fast type password and enter

    • @debajyotiray4077
      @debajyotiray4077 4 роки тому

      @@SahilTheExplorer thanks bro. I had been stuck here since yesterday. LOL

  • @anonkhamxomphou9127
    @anonkhamxomphou9127 4 роки тому +2

    When i try to put in the password it keeps saying Sorry try again pls help me

  • @trustabyss
    @trustabyss 3 роки тому +1

    It works but you have to add it to the very bottom of the file. It won't work if you add it anywhere else. I'd imagine it has something to do with the #includedir but then again I'm new to this whole GNU/Linux thing. So far I configured my server's firewall, public key access, and disabled root account.

    • @PremKumar-iu1fo
      @PremKumar-iu1fo 2 роки тому

      Thank you so much. Your comment saved a lot of my time.

  • @mariash3463
    @mariash3463 8 місяців тому +1

    What is password of sudo I don't know what you mean??

    • @Jesterv4
      @Jesterv4 2 місяці тому

      same here any fix

  • @DoanHocStudio
    @DoanHocStudio 2 роки тому +1

    thanks it took me 3 hours to fix this

  • @studyonline3236
    @studyonline3236 4 роки тому

    Video was good but I have a query. I locked a file using "chmod 700" and changed its ownership to "root:root". So, as a root, when I open it for the first time it asks for the password. That's what I want. However, when I open it using "open as root" it won't ask me the password(THE SECOND TIME). Let's say I have a private file and I just had a glance and closed it. Some random user can open it as stated in aforementioned way. My question is how to authenticate everytime?

    • @webpwnized
      @webpwnized  4 роки тому

      Based on the way the question is asked, you might encrypt the file with zip -e or other encryption. This will protect the file from being read and also require a password everytime you want to decrypt it.

  • @DiyintheGhetto
    @DiyintheGhetto 6 років тому

    Hello i have a question when my screen goes off and i wake it up by moving the mouse it keeps asking me for a password. How can i stop that. This way you are doing it will work?

    • @webpwnized
      @webpwnized  6 років тому

      Not really. You want to adjust your screenlock settings for that issue.

  • @adilmuhammad6078
    @adilmuhammad6078 3 роки тому +2

    Thank you so much and it works!

  • @taguays.a8021
    @taguays.a8021 5 років тому +1

    Excellent (and short) video

  • @econrith
    @econrith Рік тому

    I am so safe now i can do absolutely nothing in my new vanessa mint my password will not work and the terminal does not accept anything at all in it not even sudo

  • @qorabilanqizil375
    @qorabilanqizil375 2 роки тому

    Thanks to you, I, a new linux user can now su without password. I am very gratefull sir!

  • @siik-ghostface
    @siik-ghostface 4 роки тому +1

    Is sudo password same as your login password to login at login page?

    • @siik-ghostface
      @siik-ghostface 4 роки тому +1

      Nevermind the question. Duh....it is, the problem was I wasn't in sudoers file, and all I had to is add my user account to sudoers file in gno nano page window, plus add the following line from tutorial so I don't have to have to enter a password every time.

    • @siik-ghostface
      @siik-ghostface 4 роки тому +1

      I fixed my issue thanks to your video.

  • @lucahines
    @lucahines 10 днів тому

    Thank you!!!

  • @econrith
    @econrith Рік тому +1

    sudo visudo does not run in vanessa linux mint . i am forced to lose everything AGAIN. Linux getting to be a bitch

  • @duke5508
    @duke5508 3 роки тому

    Why is using a password saver

  • @mrcritique.3773
    @mrcritique.3773 6 років тому +1

    How do I find out what my password is?

    • @webpwnized
      @webpwnized  6 років тому

      Its the same password you used to log in.

    • @yankomirov4290
      @yankomirov4290 5 років тому

      @@webpwnized what if we do not know the password, for example i've got an exercise in which i've got to figure out the password. how do i find out what the password is?

    • @nerd5905
      @nerd5905 3 роки тому

      @@webpwnized but when i want to enter password it wont display on screen please help mister

  • @alexandermamani6231
    @alexandermamani6231 4 роки тому

    Thanks brother! o como dirían en mi país, gracias maquinaa!

  • @ksusmitha2840
    @ksusmitha2840 4 роки тому

    plz help me 3.28.1

  • @RideThatPiggy
    @RideThatPiggy 2 роки тому

    thanks boss

  • @k-shake1624
    @k-shake1624 2 роки тому

    Thx man

  • @sizovkirov6449
    @sizovkirov6449 4 роки тому

    thanks bro

  • @Hxr-nf1de
    @Hxr-nf1de 7 років тому +1

    Good.

  • @meanscatter1215
    @meanscatter1215 3 роки тому

    Just sht I don’t know, I know so little

  • @dzghost1272
    @dzghost1272 7 місяців тому

    Thanks buddy for the help appreciated a lot

  • @bharathlal1673
    @bharathlal1673 2 роки тому

    Thanku bro

  • @gastech2847
    @gastech2847 6 років тому

    its work thanks