LinuxSir.cn,穿越时空的Linuxsir!

 找回密码
 注册
搜索
热搜: shell linux mysql
查看: 894|回复: 0

tcp-wrapper无法限制telnet疑问

[复制链接]
发表于 2008-2-25 16:05:07 | 显示全部楼层 |阅读模式
系统FC4
装了telnet服务,并且可以远程登陆上
现在准备用tcp-wrapper来限制某些IP登陆


[root@localhost xinetd.d]# netstat -an
Active Internet connections (servers and established)
Proto Recv-Q Send-Q Local Address               Foreign Address             State      
tcp        0      0 0.0.0.0:3306                0.0.0.0:*                   LISTEN      
tcp        0      0 0.0.0.0:111                 0.0.0.0:*                   LISTEN      
tcp        0      0 0.0.0.0:10000               0.0.0.0:*                   LISTEN      
tcp        0      0 0.0.0.0:23                  0.0.0.0:*                   LISTEN      
tcp        0      0 127.0.0.1:5335              0.0.0.0:*                   LISTEN      
tcp        0      0 127.0.0.1:25                0.0.0.0:*                   LISTEN      
tcp        0      0 192.168.1.102:23            192.168.1.22:3923           ESTABLISHED
tcp        0      0 ::ffff:127.0.0.1:8005       :::*                        LISTEN      
tcp        0      0 :::8009                     :::*                        LISTEN      
tcp        0      0 :::8080                     :::*                        LISTEN      
tcp        0      0 :::80                       :::*                        LISTEN      
tcp        0      0 :::22                       :::*                        LISTEN      
tcp        0      0 :::443                      :::*                        LISTEN      
tcp        0    128 ::ffff:192.168.1.102:22     ::ffff:192.168.1.22:2430    ESTABLISHED
udp        0      0 0.0.0.0:10000               0.0.0.0:*                              
udp        0      0 0.0.0.0:5353                0.0.0.0:*                              
udp        0      0 0.0.0.0:111                 0.0.0.0:*   

telnet服务已经打开 处在侦听状态


[root@localhost xinetd.d]# cat /etc/hosts.allow
#
# hosts.allow   This file describes the names of the hosts which are
#               allowed to use the local INET services, as decided
#               by the '/usr/sbin/tcpd' server.
#

[root@localhost xinetd.d]# cat /etc/hosts.deny
#
# hosts.deny    This file describes the names of the hosts which are
#               *not* allowed to use the local INET services, as decided
#               by the '/usr/sbin/tcpd' server.
#
# The portmap line is redundant, but it is left to remind you that
# the new secure portmap uses hosts.deny and hosts.allow.  In particular
# you should know that NFS uses portmap!
telnet : 192.168.1.22 : deny

xinetd based services:
        chargen:        off
        chargen-udp:    off
        cvs:            off
        daytime:        off
        daytime-udp:    off
        echo:           off
        echo-udp:       off
        eklogin:        off
        gssftp:         off
        klogin:         off
        krb5-telnet:    on
        kshell:         off
        rsync:          off
        telnet:         on
        time:           off
        time-udp:       off

[root@localhost xinetd.d]# ls
chargen      daytime      echo-udp  klogin       rsync   time-udp
chargen-udp  daytime-udp  eklogin   krb5-telnet  telnet
cvs          echo         gssftp    kshell       time

Q1:根据资料认为telnet完全可以使用tcp-wrapper来控制
因为它受到xinet.d服务控制
但是我在hosts.deny输入相关语句
22这个IP仍然可以telnet
不知道为什么


Q2:krb5-telnet是个什么服务
当我把这个服务同样启动的时候,telnet登陆界面会有变化
多了这个提示
login: Cannot contact any KDC for requested realm while getting initial credentials
获取初始信任的时候,在请求范围内不能联系到任何一个KDC????/
您需要登录后才可以回帖 登录 | 注册

本版积分规则

快速回复 返回顶部 返回列表