亚马逊云科技

广告

安信SSL证书

广告

高级许可/拒绝过滤器

美国云服务器推荐

    在/etc/csf.allow和/etc/csf.deny里,您可以通过以下格式添加更复杂的端口和ip过滤器(您需要
    指定一个端口和一个IP地址):
    tcp/udp|in/out|s/d=port|s/d=ip|u=uid
    说明:
    tcp/udp : tcp 或 udp 或 icmp protocol
    in/out : 进入或传出连接
    s/d=port : 源或目标端口编号(或 ICMP类型)
(用_符号表示端口范围, e.g. 2000_3000)
    s/d=ip : 源或目标IP地址
    u/g=UID : 源数据包的UID或GID,反映传出连接 ,
    s/d=IP值忽略
    注意:ICMP过滤用”port”表示 s/d=port来设置ICMP类型。无论您用s还是d都一样,二者都使用iptables –icmp-type选项。”iptables -p icmp -h”表示有效ICMP类型。每个过滤器只支持一种类型。
    Examples: 例如:
    # TCP connections inbound to port 3306 from IP 11.22.33.44
    tcp|in|d=3306|s=11.22.33.44
    # TCP connections outbound to port 22 on IP 11.22.33.44
    tcp|out|d=22|d=11.22.33.44
    注意|如果省略,默认协议设置为”tcp”, 默认连接方向为”in”,所以
    # TCP connections inbound to port 22 from IP 44.33.22.11
    d=22|s=44.33.22.11
    # TCP connections outbound to port 80 from UID 99
    tcp|out|d=80||u=99
    # ICMP connections inbound for type ping from 44.33.22.11
    icmp|in|d=ping|s=44.33.22.11
    # TCP connections inbound to port 22 from Dynamic DNS address
    # www.configserver.com (for use in csf.dyndns only)
    tcp|in|d=22|s=www.configserver.com

(本文由美国主机侦探原创,转载请注明出处“美国主机侦探”和原文地址!)

主机侦探企业微信

微信扫码加好友进群

主机优惠码及时掌握

主机侦探QQ群

QQ群号:938255063

主机优惠发布与交流

温馨提示:

1、本站部分图片来源于互联网,如有侵权请联系删除。邮箱:2942802716#qq.com(#改为@)

2、本文评论没有专人回复,如果您有问题请到美国主机侦探论坛提问!

3、美国主机侦探免费为您提供美国主机购买咨询。

RAKsmart美国服务器
目录监控
多个以太网设备
返回顶部