소스 정보
- 저장소
- CyberStrikeus/CyberStrike
- 최근 소스 활동
- 2026년 4월 22일 14:54
- 감지된 SKILL.md 언어
- 영어
- 스타
- 1,653
- 포크
- 254
설치 방법
기본적으로 소스를 먼저 확인하는 Prompt가 선택됩니다. 직접 명령으로 전환하거나 로컬 사본을 다운로드할 수도 있습니다.
소스 파일 검토
설치 여부를 결정하기 전에 SKILL.md와 SkillsMP에 표시된 보조 파일을 읽어 보세요.
메뉴
기본적으로 소스를 먼저 확인하는 Prompt가 선택됩니다. 직접 명령으로 전환하거나 로컬 사본을 다운로드할 수도 있습니다.
설치 여부를 결정하기 전에 SKILL.md와 SkillsMP에 표시된 보조 파일을 읽어 보세요.
Codex 또는 Claude로 설치 이 Prompt를 복사해 Codex, Claude 또는 다른 어시스턴트에 붙여 넣으면 Skill 페이지를 검토하고 설치를 진행할 수 있습니다.
직접 명령은 검토 Prompt를 거치지 않습니다. 실행하기 전에 소스를 확인하세요.
npx skills add https://github.com/CyberStrikeus/CyberStrike --skill cis-apache24-12-2명령은 한 줄로 유지됩니다. 복사하기 전에 가로로 스크롤해 전체 내용을 확인하세요.
로컬 사본을 원하시나요? SkillsMP에서 현재 제공할 수 있는 파일을 다운로드하세요.
SOC 직업 분류 기준
SKILL.md 표시 중
| name | cis-apache24-12.2 |
| description | Ensure the Apache AppArmor Profile Is Configured Properly (Manual) |
| category | cis-apache |
| version | 2.3.0 |
| author | cyberstrike-official |
| tags | ["cis","apache","linux","apparmor","mac","profile-configuration"] |
| cis_id | 12.2 |
| cis_benchmark | CIS Apache HTTP Server 2.4 Benchmark v2.3.0 |
| tech_stack | ["linux","apache"] |
| cwe_ids | [] |
| chains_with | [] |
| prerequisites | [] |
| severity_boost | {} |
AppArmor includes customizable profiles that may be used to confine the Apache web server to enforce least privileges so that the server has only the minimal access to specified directories, files and network ports. Access is controlled by a profile defined for the apache2 process. The default AppArmor profile is typically a very permissive profile that allows read-write access to all system files. Therefore, it's important that the default profile be customized to enforce least privileges. The AppArmor utilities such as aa-autodep, aa-complain, and aa-logprof can be used to generate an initial profile based on actual usage. However thorough testing, review and customization will be necessary to ensure that the Apache profile restrictions allow necessary functionality while implementing least privilege.
With the proper implementation of AppArmor profile, vulnerabilities in the web application may be prevented from being exploited due to the additional restrictions. For example, a vulnerability that allows an attacker to read an inappropriate system files may be prevented from execution by AppArmor because the inappropriate files are not allowed by the profile. Likewise writing to an unexpected directory or execution of unexpected content can be prevented by similar mandatory security controls enforced by AppArmor.
Perform the following steps to determine if the recommended state is implemented:
Find the Apache AppArmor profile typically found in /etc/apparmor.d/usr.sbin.apache2 along with any files included by the profile such as /etc/apparmor.d/apache2.d/* and files in the /etc/apparmor.d/abstractions/ directory.
Review the capabilities and permissions granted to ensure that the profile implements least privileges for the web application. Wild-card paths such as /**, which grant access to all files and directories starting with the root level directory, should not be present in the profile. Instead read only access to specific necessary system files such as /etc/group and to the web content files such as /var/www/html/** should be given. Refer to the apparmor.d man page for additional details. Shown below are some possible example capabilities and path permissions.
capability dac_override,capability dac_read_search,capability net_bind_service,capability setgid,capability setuid,capability kill,capability sys_tty_config,. . ./usr/sbin/apache2 mr,/etc/gai.conf r,/etc/group r,/etc/apache2/** r,/var/www/html/** r,/run/apache2/** rw,/run/lock/apache2/** rw,/var/log/apache2/** rw,/etc/mime.types r,Perform the following to implement the recommended state:
Stop the Apache server
# service apache2 stopCreate a mostly empty apache2 profile based on program dependencies.
# aa-autodep apache2Writing updated profile for /usr/sbin/apache2.Set the apache2 profile in complain mode so that access violations will be allowed and logged.
# aa-complain apache2Setting /usr/sbin/apache2 to complain mode.Start the apache2 service
# service apache2 startThoroughly test the web application attempting to exercise all intended functionality so that AppArmor will generate the necessary logs of all resources accessed. The logs are sent via the system syslog utility and are typically found in either the /var/log/syslog or /var/log/messages files. Also stop and restart the web server as part of the httpd process.
Use aa-logprof to update the profile based on logs generated during the testing. The tool will prompt for suggested modifications to the profile, based on the logs. The logs may also be reviewed manually in order to update the profile.
# aa-logprofReview and edit the profile, removing any inappropriate content, and adding appropriate access rules. Directories with multiple files accessed with the same permission can be simplified with the usage of wild-cards when appropriate. Reload the updated profile using the apparmor_parser command.
# apparmor_parser -r /etc/apparmor.d/usr.sbin.apache2Test the new updated profile again and check for any new AppArmor denied logs generated. Update and reload the profile as necessary. Repeat the application tests, until no new AppArmor deny logs are created, except for access which should be prohibited.
# tail -f /var/log/syslogSet the apache2 profile to enforce mode, reload AppArmor, and then test the web site functionality again.
# aa-enforce /usr/sbin/apache2# /etc/init.d/apparmor reloadThe default Apache profile is very permissive.
v8:
v7: