Tag Info

New answers tagged

0

There is a utility called sshpass which allows you to supply a password as an option on the command line. This tool can be scripted so that it runs on multiple hosts, even in parallel. Install sshpass on your jumpbox, then take something like this: sshpass -p password ssh root@host 'hostname;date;id' and embed it in a shell loop or other method (such as ...


0

Boot your machine with a live CD, mount your hard drive, chroot to your hard drive and change password. Reboot without the live CD, now your new password should give you access.


3

The basic reason (of why this is a bad idea) is that no user (root, admin or other) should ever have access to another's user password. Simply because the password is a means of authentication. If I know some other user's password, I know their credentials (username + password), so I can login as that user, impersonating him (or her or it.) Any action I ...


42

The other two answers have told you—correctly!—that this is a Bad Idea™. But they've also told you its hard to do, requiring changing a bunch of programs. That's not true. It's very easy. You only need to change one or two configuration files. I feel its important to point this out, because you should be aware of it when logging into systems you don't ...


33

Oh dear, okay, let's start at the very beginning... We know that users' passwords are saved in /etc/passwd, but in an encrypted way No, they have been stored in /etc/passwd, and that was quite some time ago. Today passwords are stored in a so-called shadow file, most of the time /etc/shadow. but in an encrypted way, so even the root can't see them: ...


9

First of all the encrypted passwords are not in /etc/passwd, but they are in /etc/shadow. One of the reasons for this is that /etc/passwd is publicly readable (so you can e.g. find the GECOS field information for another user), and, especially with older encryption schemes could allow brute force attacks against the encrypted password. To just store the ...


0

It was long time, I have not used a Ubuntu 12.04 Linux box. I forgot its login id. I tried the following approach and got the login id. Stop at the Grub boot loader, look for options to edit and to fall back to the command-line. In my case for edit it was 'e', and for command line it was 'c'. After pressing 'e' edit key the options for boot and options for ...


5

I agree with Valmiky that you're going about it the wrong way, but the sudoers line there isn't what I'd recommend. With his line, you are all authorized to sudo to anybody else including root without password. This effectively gives you full access to the server, meaning that the /bin/su part of the line is redundant. If you should only be able to sudo to ...


9

Do not do that! That will leave your password in your shell's history! If you really have to do that, what I recommend is that you configure your sudoers file to allow a passwordless login. To do that, run the command sudo visudo and add a line like this one: reddy ALL=NOPASSWD: /bin/su - * (where reddy would be your username). If you need to give this ...


8

The sudoers file allows specifying commands to permit: username ALL=(root) NOPASSWD: /bin/foo bar baz Here username is the user you want to permit, and the command goes at the end of the line. If you specify arguments to the command, the user can only run it with exactly those arguments, but if you don't specify them here, the user can run the command ...


3

According to this source it's the key combination Ctrl+a and then x. It signifies locking the screen and unlocking it with your password.


4

As man su notes, /etc/pam.d/su is the default PAM configuration file for su. One of the options is to grant implicit elevated privileges for anyone in the wheel group: # Uncomment the following line to implicitly trust users in the "wheel" group. auth sufficient pam_wheel.so trust use_uid With this line uncommented, when you issue su without any ...


0

First of all the different runlevels are simply a question of what services are running. X (the GUI) does not start by default on runlevel 1 but that doesn't mean it can't. However, the Right Way® to start a graphical session from runlevel 1 is not to run startx but to start the login manager: sudo service lightdm start That should bring up your normal ...



Top 50 recent answers are included