zoukankan      html  css  js  c++  java
  • SELinux开启与关闭

    SELinux是「Security-Enhanced Linux」的简称,是美国国家安全局「NSA=The National Security Agency」 和SCC(Secure Computing Corporation)开发的 Linux的一个扩张强制访问控制安全模块。原先是在Fluke上开发的,2000年以 GNU GPL 发布。

    大部分使用 SELinux 的人使用的都是 SELinux 就绪的发行版,例如 Fedora、Red Hat Enterprise Linux (RHEL)、Debian或 Centos。它们都是在内核中启用 SELinux 的,并且提供一个可定制的安全策略,还提供很多用户层的库和工具,它们都可以使用 SELinux 的功能。

    SELinux的相关配置操作如下

    • 查看开启状态如何
    (方法1)/usr/sbin/sestatus -v
    (方法2)getenforce
    • 不关机临时变更状态为关闭
    setenforce 0
    • 需要关机永久变更状态为关闭,将SELINUX从enforcing变更为disabled
    [root@localhost ~]# vim /etc/selinux/config
    
    
    # This file controls the state of SELinux on the system.
    # SELINUX= can take one of these three values:
    #     enforcing - SELinux security policy is enforced.
    #     permissive - SELinux prints warnings instead of enforcing.
    #     disabled - No SELinux policy is loaded.
    #SELINUX=enforcing
    SELINUX=disabled
    # SELINUXTYPE= can take one of these two values:
    #     targeted - Targeted processes are protected,
    #     minimum - Modification of targeted policy. Only selected processes are protected. 
    #     mls - Multi Level Security protection.
    SELINUXTYPE=targeted
  • 相关阅读:
    第十二周 张文小组学习情况总结
    第五章
    第四章
    第三章
    软工实训--学习回顾2
    软工实训-- 学习回顾1
    构建之法——读书笔记(9)
    构建之法——读书笔记(8)
    构建之法——读书笔记(7)
    第13周张文小组学习情况总结
  • 原文地址:https://www.cnblogs.com/tdcqma/p/5691320.html
Copyright © 2011-2022 走看看