Please enable JavaScript.
Coggle requires JavaScript to display documents.
๐ก๏ธ 1. Apache + ModSecurity WAF Engineer Roadmap (Enterprise Level) -โฆ
๐ก๏ธ 1. Apache + ModSecurity WAF Engineer Roadmap (Enterprise Level)
๐ก๏ธ 1. Apache + ModSecurity WAF Engineer Roadmap (Enterprise Level)
๐ 1.1 Target Roles
๐จโ๐ป 1.1.1 Application Security Engineer
๐น Web Application Protection
๐น OWASP Top 10 Mitigation
๐น WAF Rule Management
๐ก๏ธ 1.1.2 Web Application Security Engineer
๐น Apache Hardening
๐น ModSecurity Deployment
๐น Attack Detection
๐ฅ 1.1.3 Cybersecurity Engineer (WAF)
๐น WAF Architecture
๐น Security Policy Management
๐น Incident Response
๐ 1.1.4 SOC Analyst L2 Web Security
๐น WAF Alert Investigation
๐น Attack Analysis
๐น Log Monitoring
๐ง 1.1.5 Linux Security Engineer
๐น Apache Administration
๐น Linux Hardening
๐น Service Security
โ๏ธ 1.1.6 DevSecOps Security Engineer
๐น CI/CD WAF Integration
๐น Security Automation
๐น Secure Deployment
๐ 2. Apache HTTP Server Fundamentals
๐ 2.1 Apache Architecture
๐๏ธ 2.1.1 Apache Core Components
๐น HTTPD Service (Apache Engine , start, stop, systemctl)
๐น Modules (Functionality Extensions)
๐น Configuration Files (Server Behavior)
๐น Virtual Hosts (Multiple Websites / Applications)
โ๏ธ 2.1.2 Apache Process Model
MPM : Multi Processing Modules
๐ข Prefork MPM
๐น Process Based
๐น Older PHP Applications
One process per connection
๐ก Worker MPM
๐น Thread Based
๐น Better Performance
Multi-thread based
๐ต Event MPM
๐น Modern Production Usage
๐น High Concurrent Traffic
High-performance asynchronous model
๐ 2.2 Apache Important Files
๐ 2.2.1 Main Configuration
RHEL/CentOS:
/etc/httpd/conf/httpd.conf
Ubuntu:
/etc/apache2/apache2.conf
๐ 2.2.2 Configuration Directory
Ubuntu:
/etc/apache2/
Includes:
๐ sites-available
๐น Virtual Host Templates
๐ sites-enabled
๐น Active Websites
๐ mods-enabled
๐น Enabled Modules
๐ง 2.3 Apache Service Management
โถ๏ธ Start Apache
systemctl start httpd
systemctl start apache2
๐ Restart Apache
systemctl restart httpd
๐ Check Status
systemctl status httpd
๐งช Configuration Testing
apachectl configtest
๐ 3. Apache Security Hardening
๐ก๏ธ 3.1 Information Disclosure Protection
Remove Server Version
ServerTokens Prod
ServerSignature Off
Disable Directory Listing
Options -Indexes
Hide Error Details
ErrorDocument 403 /403.html
๐ 3.2 Access Control
Allow/Deny Based Access
Example:
Require ip 10.10.10.0/24
Block Specific IP:
Require not ip 192.168.1.50
๐ 3.3 SSL/TLS Security
SSL/TLS security is a technology used to encrypt communication between two systems so attackers cannot read or modify the data being transmitted.
Tools:
๐น OpenSSL
๐น testssl.sh
๐น SSL Labs
Commands:
openssl s_client -connect domain.com:443
Apache SSL Configuration:
SSLEngine On
SSLCertificateFile
SSLCertificateKeyFile
๐ซ 3.4 Disable Dangerous HTTP Methods
Block:
TRACE
PUT
DELETE
Configuration:
TraceEnable Off
๐ 3.5 Apache Logging
Access Log:
/var/log/httpd/access_log
Error Log:
/var/log/httpd/error_log
Log Analysis Tools:
๐น grep
๐น awk
๐น sed
๐น ELK Stack
๐ก๏ธ 4. ModSecurity WAF Fundamentals
๐ฅ 4.1 What is ModSecurity?
Apache Security Module
Provides:
๐น Request Inspection
๐น Attack Detection
๐น Blocking Malicious Traffic
๐น Security Logging
๐๏ธ 4.2 ModSecurity Architecture
Client
โ
Apache Web Server
โ
ModSecurity Engine
โ
Rules Engine
โ
Allow / Block Decision
โ๏ธ 5. Installing ModSecurity on Linux
๐ง 5.1 RHEL Installation
Install Packages:
yum install mod_security mod_security_crs
Restart:
systemctl restart httpd
๐ง 5.2 Ubuntu Installation
Install:
apt install libapache2-mod-security2
Enable Module:
a2enmod security2
Restart:
systemctl restart apache2
๐ 6. ModSecurity Configuration
๐ 6.1 Main Configuration
Location:
/etc/modsecurity/
Main File:
modsecurity.conf
โ๏ธ 6.2 Enable Detection Engine
Detection Only Mode:
SecRuleEngine DetectionOnly
Blocking Mode:
SecRuleEngine On
Disable:
SecRuleEngine Off
๐ 7. ModSecurity Rules Development
๐งฉ 7.1 Rule Structure
SecRule
VARIABLE
OPERATOR
ACTIONS
Example:
SecRule ARGS
"@contains
select"
"id:1001,deny,status:403"
Explanation:
๐น ARGS
Request Parameters
๐น Operator
contains
String Matching
๐น Action
deny
Block Request
๐ฅ 8. OWASP Core Rule Set (CRS)
๐ก๏ธ 8.1 What is CRS?
Community Managed Security Rules
Protects Against:
๐ SQL Injection
๐ XSS
๐ฅ๏ธ RCE
๐ File Inclusion
๐ Authentication Attacks
๐ CRS Location
/usr/share/modsecurity-crs/
Enable CRS:
Include rules/*.conf
๐จ 9. Attack Detection Practical Labs
๐ 9.1 SQL Injection Detection
Attack Example:
' OR 1=1 --
Detection:
SQL Injection Rules
Logs:
/var/log/apache2/modsec_audit.log
๐ฅ๏ธ 9.2 Remote Code Execution
Example:
; cat /etc/passwd
Detection:
Command Injection Rules
๐ 9.3 Cross Site Scripting
Example:
<script>alert(1)</script>
Detection:
XSS Rules
๐ 10. ModSecurity Logging
๐ 10.1 Audit Logs
Location:
/var/log/modsec_audit.log
๐ Analyze Logs
Commands:
cat modsec_audit.log
grep "403" modsec_audit.log
๐ Enterprise Integration
Send Logs To:
๐น ELK Stack
๐น Splunk
๐น QRadar
๐น Sentinel
๐งช 11. Security Testing Tools
๐ 11.1 Web Testing
๐ท๏ธ Burp Suite
HTTP Request Testing
๐ OWASP ZAP
Automated Scanning
๐ฅ Nikto
Web Server Scanner
๐ 11.2 Attack Simulation
SQLMap
SQL Injection Testing
Nmap
Service Discovery
Curl
HTTP Testing
๐ข 12. Enterprise WAF Operations
๐ 12.1 Daily Tasks
๐ Review WAF Alerts
๐ Analyze Attack Logs
๐ง Tune False Positives
๐ Generate Security Reports
๐จ 12.2 Incident Response
Detection
โ
Investigation
โ
Rule Tuning
โ
Blocking
โ
Report
โ๏ธ 13. ModSecurity Rule Tuning
โ False Positive Example
Legitimate Request Blocked
Solution:
Create Exception Rule
Example:
SecRuleRemoveById 942100
๐ 14. Enterprise Deployment Architecture
๐ Internet
โ
๐ฅ Firewall
โ
๐ก๏ธ Apache + ModSecurity WAF
โ
๐ฅ๏ธ Application Server
โ
๐๏ธ Database
๐ 15. Hands-On Enterprise Labs
๐งช Lab 1
Install Apache
Configure Virtual Host
Enable SSL
๐งช Lab 2
Install ModSecurity
Enable CRS
Detect SQL Injection
๐งช Lab 3
Create Custom Rules
Block Attacks
๐งช Lab 4
Send WAF Logs To ELK
๐งช Lab 5
Perform Incident Investigation
๐ฏ 16. Job Interview Preparation
โ Explain ModSecurity Architecture
โ Difference Between WAF and Firewall
โ How CRS Detects Attacks
โ How To Tune False Positives
โ How To Write Custom Rules
โ How To Investigate WAF Alerts
โ How Apache Security Hardening Works
๐ 17. Final Enterprise Skill Set
๐ง Linux Administration
๐ Apache Administration
๐ก๏ธ ModSecurity WAF
๐ OWASP CRS
๐ฅ Web Attack Detection
๐ WAF Log Analysis
๐งช Security Testing
๐จ Incident Response
โ๏ธ Security Automation