In addition to Weibo, there is also WeChat
Please pay attention

WeChat public account
Shulou
            
                    
                
2025-11-04 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >
Share
Shulou(Shulou.com)06/01 Report--
This article introduces the relevant knowledge of "detailed introduction of chcon command". In the operation process of actual cases, many people will encounter such difficulties. Next, let Xiaobian lead you to learn how to deal with these situations! I hope you can read carefully and learn something!
chcon command: modifies the security context of an object (file). For example: user: role: type: security level.
Command Format:
Chcon [OPTIONS…] CONTEXT FILES…..
Chcon [OPTIONS…] -reference=PEF_FILES FILES…
Description:
CONTEXT is the security context to set
FILES object (file)
--reference object referenced
PEF_FILES Reference File Context
FILES Apply the reference file context as my context.
OPTIONS are as follows:
-f enforce
-R Recursively modify the security context of an object
-r ROLE Modify the configuration of security context roles
-t TYPE Modify the configuration of security context types
-u USER modifies the configuration of the security context user
-v Display lengthy messages
-l, --range=RANGE Modify the security level in a security context
Example:
1、ftp
//If you want to share files anonymously
chcon -R -t public_content_t /var/ftp
//If you want to setup a directory where you can upload files
chcon -t public_content_rw_t /var/ftp/incoming
//You must also turn on the boolean allow_ftpd_anon_write
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

The market share of Chrome browser on the desktop has exceeded 70%, and users are complaining about
The world's first 2nm mobile chip: Samsung Exynos 2600 is ready for mass production.According to a r
A US federal judge has ruled that Google can keep its Chrome browser, but it will be prohibited from
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope





            
            About us Contact us Product review car news thenatureplanet
More Form oMedia: AutoTimes. Bestcoffee. SL News. Jarebook. Coffee Hunters. Sundaily. Modezone. NNB. Coffee. Game News. FrontStreet. GGAMEN
© 2024 shulou.com SLNews company. All rights reserved.