Languages
[Edit]
EN

Putty - automatically login to root account with MTPuTTY when login to root account is not permitted by SSH server

8 points
Created by:
AnnLen
9180

In this article, we would like to show you how to automatically login to a root account via SSH when such login operation is disabled for security reasons. The article shows how to configure a login operation with MTPuTTY.

Simple steps:

  1. click Server -> Add server...,
  2. set Connection parameters tab:
    Server name:      my-server.com
    Protocol:         SSH
    Display name:     root@my-server.com
    User name:        my_user_name
    Password:         my_secret_user_password
    You can set last properties as you feel, e.g.:
    Password in command line (SSH only):                     unchecked
    Wait period before typing password (in milliseconds):    1000
  3. go to Script tab and paste following code:
    ###_SLEEP:1000
    su -l root
    ###_SLEEP:1000
    my_secret_root_password

    Where: 400 can be replaced by any time of waiting for next operation in milliseconds.

  4. click Ok button,
  5. check if you are able to login as root now.

Steps: 2 and 3 on screenshots:

MTPuTTY with login as root example
MTPuTTY with login as root example
Example configuration for MTPuTTY login as any user via SSH
Step 2: Example configuration for MTPuTTY login as any user via SSH
Script for MTPuTTY login as root when root in SSH server is disabled
Step 3: Script for MTPuTTY login as root when root in SSH server is disabled
Native Advertising
50 000 ad impressions - 449$
🚀
Get your tech brand or product in front of software developers.
For more information contact us:
Red dot
Dirask - friendly IT community for everyone.

❤️💻 🙂

Join