Hello World !
分类: LINUX
2013-03-17 17:17:47
[root@Demo Packages]# rpm -ivh xinetd-2.3.14-33.el6.i686.rpm
warning: xinetd-2.3.14-33.el6.i686.rpm: Header V3 RSA/SHA256 Signature, key ID fd431d51: NOKEY
Preparing... ########################################### [100%]
1:xinetd ########################################### [100%]
[root@Demo cdrom]# rpm -ivh telnet-
telnet-0.17-47.el6.i686.rpm telnet-server-0.17-47.el6.i686.rpm
[root@Demo cdrom]# rpm -ivh telnet-*
warning: telnet-0.17-47.el6.i686.rpm: Header V3 RSA/SHA256 Signature, key ID fd431d51: NOKEY
Preparing... ########################################### [100%]
1:telnet-server ########################################### [ 50%]
2:telnet ########################################### [100%]
[root@Demo Packages]# cd /etc/xinetd.d/
[root@Demo xinetd.d]# vi telnet
# 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
}
[root@Demo xinetd.d]# service xinetd restart
Stopping xinetd: [FAILED]
Starting xinetd: [ OK ]
[root@Demo etc]# telnet 127.0.0.1
Trying 127.0.0.1...
Connected to 127.0.0.1.
Escape character is '^]'.
Red Hat Enterprise Linux Server release 6.2 (Santiago)
Kernel 2.6.32-220.el6.i686 on an i686
login: root
Password:
Login incorrect
login: admin
Password:
Last login: Sun Mar 17 10:05:35 from 192.168.1.100
[admin@Demo ~]$ su -
Password:
[root@Demo ~]#
使用root登录(默认root无法登陆):
[root@Demo etc]# mv securetty securetty.bak
[root@Demo etc]# telnet 127.0.0.1
Trying 127.0.0.1...
Connected to 127.0.0.1.
Escape character is '^]'.
Red Hat Enterprise Linux Server release 6.2 (Santiago)
Kernel 2.6.32-220.el6.i686 on an i686
login: root
Password:
Last login: Mon Mar 18 00:52:51 from 172.1.1.1
[root@Demo ~]#
修改Telnet服务端的端口(默认为23):
[root@Demo etc]# vi /etc/services
telnet 5023/tcp
telnet 5023/udp
[root@Demo etc]# telnet 127.0.0.1 5023
Trying 127.0.0.1...
Connected to 127.0.0.1.
Escape character is '^]'.
Red Hat Enterprise Linux Server release 6.2 (Santiago)
Kernel 2.6.32-220.el6.i686 on an i686
login: