Iptabels防火墙和SElinux
两者的区别:
iptables用于设置防火墙(firewall), 即管理内外通信。
iptables是Linux下功能强大的应用层防火墙工具
iptables 能做到“控制内部机器上网与不上网,访问哪些网站的控制”
但日志只能记录关于访问ip数据的相关信息
SELinux主要用于对文件(file), 文件夹 (directory), 过程(process)的限制
SELinux是美国国家安全局发布的一个强制访问控制系统
临时关闭防火墙 systemctl stop firewalld
永久防火墙开机自启动 systemctl disable firewalld
临时打开防火墙 systemctl start firewalld
防火墙开机启动 systemctl enable firewalld
查看防火墙状态 systemctl status firewalld
临时关闭SELinux setenforce 0
临时打开SELinux setenforce 1
开机关闭SELinux
编辑/etc/selinux/config文件,将SELINUX的值设置为disabled,如下图。下次开机SELinux就不会启动了。
查看SELinux状态
执行getenforce命令
Iptabels防火墙和SElinux的更多相关文章
- Linux关闭防火墙、SELinux
使用root权限: Linux关闭防火墙: 1. chkconfig –list|grep iptables 2. chkconfig iptables off 永久关闭防火墙 3. chkconfi ...
- SpringCloud的应用发布(四)vmvare+linux,防火墙和selinux
一.vmvare网络配置为nat模式 二.vmvare的网络设置为桥接bridge模式 1.linux 网卡的ip获取方式dhcp 三.关闭linux的防火墙和selinux 1.临时关闭防火墙 sy ...
- CentOS7 关闭防火墙和selinux
本文将简单介绍在CentOS7上如何临时和永久关闭防火墙和selinux. 关闭防火墙 # 查看防火墙状态 [root@localhost ~]# systemctl status firewalld ...
- Linux_防火墙与SElinux
一.防火墙与SElinux 1.防火墙和selinux 防火墙 iptables 默认允许所以 firewalld 默认拒绝所有 ebtables 不认识,不管 se ...
- Centos 7 安装 设置 IP地址,DNS,主机名,防火墙,端口,SELinux (实测+笔记)
环境: 系统硬件:vmware vsphere (CPU:2*4核,内存2G,双网卡) 系统版本:CentOS-7.0-1406-x86_64-DVD.iso 安装步骤: 1.虚拟系统安装 1.1 使 ...
- CentOS 关闭防火墙和selinux
1)关闭防火墙(每个节点) [Bash shell] 1 2 service iptables stop chkconfig iptables off 2)关闭selinux(重启生效) [Bash ...
- Centos7关闭防火墙与selinux
CentOS 7.0默认使用的是firewall作为防火墙 直接关闭防火墙 systemctl stop firewalld.service #停止firewall systemctl disable ...
- 永久关闭防火墙和selinux
临时关闭selinux: setenforce 0 //设置SELinux 成为permissive模式 彻底禁用selinux: 使用root用户,vim /etc/sysconfig/sel ...
- linux关闭防火墙及selinux
RHEL6.5 查看linux防护墙状态: service iptables status 关闭linux防火墙: 1)永久关闭,重启后生效 开启: chkconfig iptables on 关闭: ...
随机推荐
- pycharm远程调试配置
目录: 安装pycharm 配置pycharm远程调试 使用测试 一.安装pycharm(略) 二.配置pycharm远程调试 1.菜单--->Tools--->Deployment--- ...
- 推荐一些好的linux学习网站
菜鸟教程:这个网站有jsp,php,c,android等等入门教程,很适合入门的新手和想多学一门语言的人 传送门http://www.runoob.com/ linux命令那么多,怎么记,给一个lin ...
- 我的vim(持续更新)
保存并退出:wq 退出但不保存修改:q! 不退出vi使用shell(bash)命令:!bash (如果想回到vi,bash下输入exit回车) 设置行号 :set nu 取消行号:set nonu 设 ...
- Write your own Terraform provider: Part 1
转自:https://container-solutions.com/write-terraform-provider-part-1/ This is the first part of a seri ...
- C/S架构程序多种类服务器之间实现单点登录
(一) 在项目开发的过程中,经常会出现这样的情况:我们的产品包括很多,以QQ举例,如登陆.好友下载.群下载.网络硬盘.QQ游戏.QQ音乐等,总不能要求用户每次输入用户名.密码吧,为解决这个问题,高手提 ...
- JS正则表达式验证身份证号码
function isCardNo(card) { // 身份证号码为15位或者18位,15位时全为数字,18位前17位为数字,最后一位是校验位,可能为数字或字符X var reg = /(^\d{1 ...
- 函数防抖(Debounce)、函数节流 (Throttle)
一篇介绍文章:https://zhuanlan.zhihu.com/p/38313717 演示示例:http://demo.nimius.net/debounce_throttle/ 函数防抖(Deb ...
- Spring Cloud Stream
Spring Cloud Stream是Spring Cloud的组件之一,是一个为微服务应用构建消息驱动能力的框架. 1.导入引用 <dependency> <groupId> ...
- win7重装系统笔记
制作U盘启动盘:链接 原文链接:链接 开机进入bios界面(华硕:F2) 按方向左右键进入:Boot选项,将“Lunch CSM”设置为“Enabled” 方向键选择“Security”,将“Secu ...
- C语言中基本的数据类型
一般来说,一个C的工程中一定要做一些这方面的工作,因为你会涉及到跨平台,不同的平台会有不同的字长,所以利用预编译和typedef可以让你最有效的维护你的代码.为了用户的方便,C99标准的C语言硬件为我 ...