寵物展會(huì)2025年時(shí)間表
785
2022-05-30
ECS信息
規(guī)格:2vCPUs | 4GiB | kc1.large.2
鏡像:openEuler 20.03 64bit with ARM | 公共鏡像
linux SELinux 查看配置文件
# stat /etc/sysconfig/selinux File: /etc/sysconfig/selinux -> ../selinux/config Size: 17 Blocks: 0 IO Block: 4096 symbolic link Device: fd02h/64770d Inode: 141813 Links: 1 Access: (0777/lrwxrwxrwx) Uid: ( 0/ root) Gid: ( 0/ root) Access: 2021-10-04 15:57:54.203285534 +0800 Modify: 2020-05-18 10:35:49.716000000 +0800 Change: 2020-05-18 10:35:49.716000000 +0800 Birth: 2020-05-18 10:35:49.716000000 +0800
# cat /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=disabled # SELINUXTYPE= can take one of these three values: # targeted - Targeted processes are protected, # minimum - Modification of targeted policy. Only selected processes are protected. # mls - Multi Level Security protection. SELINUXTYPE=targeted
SELINUX的模式有三種:enforcing、permissive、disabled
SELINUXTYPE的策略有三種:targeted、minimum、mls
安裝tree
# tree -bash: tree: command not found # yum install tree Last metadata expiration check: 2:46:11 ago on Mon 04 Oct 2021 01:19:18 PM CST. Dependencies resolved. ===================================================================================================================================== Package Architecture Version Repository Size ===================================================================================================================================== Installing: tree aarch64 1.7.0-18.oe1 OS 49 k Transaction Summary ===================================================================================================================================== Install 1 Package Total download size: 49 k Installed size: 165 k Is this ok [y/N]: y Downloading Packages: tree-1.7.0-18.oe1.aarch64.rpm 1.6 MB/s | 49 kB 00:00 ------------------------------------------------------------------------------------------------------------------------------------- Total 1.5 MB/s | 49 kB 00:00 Running transaction check Transaction check succeeded. Running transaction test Transaction test succeeded. Running transaction Preparing : 1/1 Installing : tree-1.7.0-18.oe1.aarch64 1/1 Verifying : tree-1.7.0-18.oe1.aarch64 1/1 Installed: tree-1.7.0-18.oe1.aarch64 Complete!
# pwd /etc/selinux
# tree . ├── config ├── restorecond.conf ├── restorecond_user.conf ├── semanage.conf └── targeted ├── booleans.subs_dist ├── contexts │ ├── customizable_types │ ├── dbus_contexts │ ├── default_contexts │ ├── default_type │ ├── failsafe_context │ ├── files │ │ ├── file_contexts │ │ ├── file_contexts.homedirs │ │ ├── file_contexts.local │ │ ├── file_contexts.subs │ │ ├── file_contexts.subs_dist │ │ └── media │ ├── initrc_context │ ├── lxc_contexts │ ├── openssh_contexts │ ├── removable_context │ ├── securetty_types │ ├── sepgsql_contexts │ ├── snapperd_contexts │ ├── systemd_contexts │ ├── userhelper_context │ ├── users │ │ ├── guest_u │ │ ├── root │ │ ├── staff_u │ │ ├── sysadm_u │ │ ├── unconfined_u │ │ ├── user_u │ │ └── xguest_u │ ├── virtual_domain_context │ ├── virtual_image_context │ └── x_contexts ├── logins ├── policy │ └── policy.31 ├── setrans.conf └── seusers 6 directories, 38 files
雖然selinux配置起來(lái)有些復(fù)雜,但是強(qiáng)烈建議在生產(chǎn)環(huán)境中開(kāi)啟selinux!為了安全著想,安全生產(chǎn)才是基線!
學(xué)習(xí)資料
彈性云服務(wù)器 ECS
openEuler-官網(wǎng)
openEuler-B站
openEuler-慕課
openEuler-文檔
鯤鵬社區(qū)
歡迎各位同學(xué)一起來(lái)交流學(xué)習(xí)心得^_^
Linux openEuler
版權(quán)聲明:本文內(nèi)容由網(wǎng)絡(luò)用戶投稿,版權(quán)歸原作者所有,本站不擁有其著作權(quán),亦不承擔(dān)相應(yīng)法律責(zé)任。如果您發(fā)現(xiàn)本站中有涉嫌抄襲或描述失實(shí)的內(nèi)容,請(qǐng)聯(lián)系我們jiasou666@gmail.com 處理,核實(shí)后本網(wǎng)站將在24小時(shí)內(nèi)刪除侵權(quán)內(nèi)容。