iptables - CentOS下如何限制指定用户只能在指定IP登录?
phpcn_u1582
phpcn_u1582 2017-04-24 15:59:43
0
1
624

如题。用 hosts 针对的是所有用户。
貌似可以用配置 /etc/ssh/sshd_config 方式去限制。
貌似也可以配置 iptables 去限制。
但不知哪种方法更好?该如何配置。能否详细讲解?谢谢!

phpcn_u1582
phpcn_u1582

reply all (1)
伊谢尔伦

In view of LZ’s requirements, it is recommended to use sshd_config, iptables is not suitable.
Configuration: AllowUsers wangshuo@172.31.11.237
Note that after modification, restart the service: service sshd restart

    Latest Downloads
    More>
    Web Effects
    Website Source Code
    Website Materials
    Front End Template
    About us Disclaimer Sitemap
    php.cn:Public welfare online PHP training,Help PHP learners grow quickly!