Allow telnet access by the root user
RHEL6:
[Root @ clovem ~] # Yum install telnet-server-y // install telnet server
[Root @ clovem ~] # Cat/etc/xinetd. d/telnet // enable the telnet hosting service
# Default: on
# Description: The telnet server serves telnet sessions; it uses \
# Unencrypted username/password pairs for authentication.
Service telnet
{
Flags = REUSE
Socket_type = stream
Wait = no
User = root
Server =/usr/sbin/in. telnetd
Log_on_failure + = USERID
Disable = no // change yes to no
}
[Root @ clovem ~] # Service xinetd restart // restart the managed service to make the configuration file take effect
Follow these steps to make the root user logon take effect:
[Root @ clovem ~] # Mv/etc/securetty. bak
In this way, the root user can directly access the Linux host. However, we recommend that you do not do this. You can also switch to the root user after a common user enters, with the root permission.
Red Hat Enterprise Linux AS release 4
Need to modify: krb5-telnet
[Root @ rawlnx ~] # Cat/etc/xinetd. d/krb5-telnet
# Default: off
# Description: The authenticated telnet server accepts normal telnet sessions ,\
# But can also use Kerberos 5 authentication.
Service telnet
{
Flags = REUSE
Socket_type = stream
Wait = no
User = root
Server =/usr/kerberos/sbin/telnetd
Log_on_failure + = USERID
Disable = no
}
After the configuration is complete, restart the xinetd service.
Solaris: Comments the CONSOLE line of this file and takes effect directly.
-Bash-3.00 # cat/etc/default/login | grep CONSOLE
# If CONSOLE is set, root can only login on that device.
# CONSOLE =/dev/console
Recommended reading:
Write a trojan program in Linux C to steal the root user password
Researchers found the most advanced Android Trojan Horse
Sharing the trojan program in Linux
Security researchers: More Trojans lock the target Linux System
Scan Trojan viruses with anti-virus software clamav in Linux