



















本文参考以下链接:
基于 CVE-1999-0526 漏洞的披露,对系统 X 服务的 6000 端口进行关闭
有三种方式:
nolisten 参数rm -f /usr/bin/X
vim /usr/bin/X
###################
添加如下内容
#!/bin/bash
exec /usr/bin/Xorg "$@" -nolisten tcp
exit 0
####################
chmod 777 /usr/bin/X
kill -9 进程号 # ps -elf |grep X 显示的进程号
rm -f /usr/bin/X
ln -s /usr/bin/Xorg /usr/bin/X
kill -9 进程号 # pe -elf | grep Xorg 显示的进程号
在测试过程中出现过杀死 X 服务进程后没有自启的情况,可尝试使用 init 3 && init 5 尝试重新启动 X 服务
# 开启除6000端口以外的所有端口(6000端口无法访问)
systemctl start firewalld
firewall-cmd --permanent --zone=public --add-port=1-65535/udp
firewall-cmd --permanent --zone=public --add-port=1-5999/tcp
firewall-cmd --permanent --zone=public --add-port=6001-65535/tcp
firewall-cmd --reload
firewall-cmd --list-all
# 恢复(6000端口可以访问)
firewall-cmd --permanent --zone=public --add-port=6000/tcp
firewall-cmd --reload
firewall-cmd --list-all
以上
此内容由惯性聚合(RSS阅读器)自动聚合整理,仅供阅读参考。 原文来自 — 版权归原作者所有。