SELinux 설정 audit.log httpd_read_user_content httpd_enable_homedirs httpd_can_network_connect > 개발

본문 바로가기
사이트 내 전체검색

개발

SELinux 설정 audit.log httpd_read_user_content httpd_enable_homedirs httpd_can_network_connect

페이지 정보

profile_image
작성자 관리자 (61.♡.26.87)
댓글 0건 조회 2,142회 작성일 20-09-27 18:34

본문

SELinux 에 대해서 논란은 항상 있다.

사용을 해야 되는 것은 맞는 것 같은데,
너무 난해하고 해결하기 어려운 오류들이 발생하여 그냥 꺼 버릴까??

나의 결론은,
일단 사용을 하는 것으로 하고,
문제 발생시 해당 항목이나 기능을 off 하는 방향으로 가자!!

그래서, 아래와 같이 하나하나 추가하기로 한다.



ㅁ audit2why 라는 명령어로 audit.log 파일에 설명을 볼 수 있다.
```
# audit2why < /var/log/audit/audit.log
```
https://www.lesstif.com/ws/%EC%97%90%EB%9F%AC-%EC%A1%B0%ED%9A%8C%ED%95%98%EA%B8%B0-48988534.html



ㅁ 사용자 디렉토리 관련해서 httpd_read_user_content httpd_enable_homedirs 설정해 주기
```
# setsebool -P httpd_read_user_content 1
# setsebool -P httpd_enable_homedirs 1
```
https://qastack.kr/server/461504/what-is-the-difference-between-httpd-read-user-content-and-httpd-enable-homedirs
https://www.lesstif.com/system-admin/setroubleshoot-selinux-19857527.html
https://www.lesstif.com/ws/selinux-troubleshooting-48988293.html



ㅁ httpd_can_network_connect 설정
```
# setsebool -P httpd_can_network_connect 1
```
https://itzone.tistory.com/646



ㅁ httpd_unified 에 대한 고찰
```
# setsebool -P httpd_unified 1
```
https://www.digitalocean.com/community/tutorials/how-to-install-the-apache-web-server-on-centos-8
https://www.lesstif.com/system-admin/rhel-centos-7-httpd-selinux-policy-27984832.html



ㅁ SELinux 설정 중 httpd 관련 bool 설정들
```
# getsebool -a | grep httpd
```


ㅁ SELinux 동작모드 변경
SELinux 는 enforce, permissive, disable 세 가지 동작 모드가 있다.
현재 모드 확인
```
# getenforce
```
permissive 모드로 변경
```
# setenforce 0
```
현재 모드 다시 확인
```
# getenforce
```
enforce 모드로 변경
```
# setenforce 1
```

추천0

댓글목록

등록된 댓글이 없습니다.

Total 386건 1 페이지
  • RSS
개발 목록
번호 제목 조회 추천 날짜
386144004-07
385681002-02
384805001-09
383959012-25
382904012-15
381756012-10
380377012-03
379399011-26
378379011-04
377965009-08
3761196008-11
3751289008-10
3741569007-10
3731080007-03
3721479006-06
3711282004-23
3701271004-20
3692288004-19
368970004-12
3671599004-11

검색


사이트 정보

Copyright © Baragi.Net. All rights reserved.