Chinaunix首页 | 论坛 | 博客
  • 博客访问: 175690
  • 博文数量: 34
  • 博客积分: 2245
  • 博客等级: 大尉
  • 技术积分: 360
  • 用 户 组: 普通用户
  • 注册时间: 2009-11-23 11:41
文章分类

全部博文(34)

文章存档

2011年(1)

2010年(28)

2009年(5)

分类: LINUX

2010-03-08 11:45:19

第一步,我们在Linux系统下,修改/etc/X11/xdm/Xaccess文件,找到下面的语句:
# * #any  host  can  get  a  login  window
去掉最前面的#号,成为
 * #any  host  can  get  a  login  window
第二步,我们修改/etc/X11/gdm/gdm.conf文件,找到下面的语句:
[xdmcp]
# Distributions: Ship with this off.  It is never a safe thing to leave
# out on the net.  Setting up /etc/hosts.allow and /etc/hosts.deny to only
# allow local access is another alternative but not the safest.
# Firewalling port 177 is the safest if you wish to have xdmcp on.
# Read the manual for more notes on the security of XDMCP.
Enable=false
将其中的Enable=false 改为
Enable=true 或 Enable=1。
同时我们要确保存在下面的语句,因为177端口是我们要配置的xdmcp服务的监听端口,我们在后面配置xmanager将看到。
去掉最前面的#号,成为
Port=177
第三步,我们要修改/etc/inittab文件.
将语句改为id:5:initdefault:
同时,找到如下文字所在的地方,
x:5:respawn:/etc/X11/prefdm -nodaemon将它修改为
x:5:respawn:/usr/bin/gdm
第四步,我们修改/etc/X11/xdm/xdm-config的最后一行,在displayManager.requestPort:0前面加上一个!号
!DisplayManager.requestPort:    0
第五步,我们修改确保/etc/X11/xdm/Xservers的属性为444,/etc/X11/xdm/Xsetup_0的属性为755,在RedHat 9.0中,我们可以看到这两个文件默认的属性就是444和775,因此不用修改。
 最后,如果我们的Linux机器配置有防火墙,为防止防火墙将通过177端口(即xdmcp服务)的数据过虑,我们必须加上如下的规则:
   iptables  -A  INPUT  -p udp -s 0/0 -d 0/0 --dport 177 -j ACCEPT
阅读(2910) | 评论(0) | 转发(0) |
给主人留下些什么吧!~~