Skip to main content
skill CX Codex

analyzing-web-server-logs-for-intrusion — Claude Code skill: install

This skill parses Apache and Nginx logs, flags attack patterns, and builds a findings report. Use it for incident analysis or monitoring checks.

Install into Claude Code · Skills CLI (Vercel) All methods and platforms ↓
npx skills add mukul975/Anthropic-Cybersecurity-Skills --skill analyzing-web-server-logs-for-intrusion -a claude-code
Open on GitHub

What analyzing-web-server-logs-for-intrusion does

The skill extracts the IP, timestamp, method, URI, status code, response size, user-agent, and referer from each entry. It checks for SQL injection, LFI, path traversal, and XSS, detects nikto, sqlmap, dirbuster, gobuster, and wfuzz signatures, and flags brute-force activity when one IP sends more than 50 POST requests to login endpoints within 5 minutes.

The package includes scripts/agent.py. It accepts Apache Combined Log Format and the default Nginx format, adds GeoIP context, and looks for outliers in request frequency and response size. The command writes web_intrusion_report.json. Python 3.8+ and the geoip2 and user-agents dependencies are required for a run.

What it helps with

  • parse Apache and Nginx access logs
  • spot SQL injection and XSS in request URIs
  • detect LFI and path traversal attempts
  • identify scanners by user-agent
  • prioritize findings with GeoIP and anomaly checks

Example prompts for the agent

  • Analyze /var/log/nginx/access.log for web intrusion indicators and write a findings report.
  • Run scripts/agent.py on /var/log/nginx/access.log with GeoLite2-City.mmdb, saving the result as web_intrusion_report.json.
  • Check this access log for SQL injection, LFI, path traversal, XSS, scanner signatures, and brute-force POST activity.

How to install analyzing-web-server-logs-for-intrusion

1Skills CLI (Vercel)

npx skills add mukul975/Anthropic-Cybersecurity-Skills --skill analyzing-web-server-logs-for-intrusion -a claude-code

2Manually: put the files in place

~/.claude/skills/analyzing-web-server-logs-for-intrusion/SKILL.md

Copy the whole skill folder; for one project use .claude/skills/analyzing-web-server-logs-for-intrusion/

Step by step, with commands for each platform: How to install skills in Claude Code: five ways

Questions about analyzing-web-server-logs-for-intrusion

How do I install analyzing-web-server-logs-for-intrusion in Claude Code?

Run npx skills add mukul975/Anthropic-Cybersecurity-Skills --skill analyzing-web-server-logs-for-intrusion -a claude-code, run npx skills add mukul975/Anthropic-Cybersecurity-Skills --skill analyzing-web-server-logs-for-intrusion -a claude-code again, then check ~/.claude/skills/analyzing-web-server-logs-for-intrusion/SKILL.md.

What does analyzing-web-server-logs-for-intrusion do?

It parses Apache and Nginx access logs, checks attack and scanner signatures, measures request and response anomalies, and produces a prioritized JSON findings report with GeoIP context.

What does analyzing-web-server-logs-for-intrusion need to run?

Use Apache Combined Log Format or the default Nginx format, Python 3.8+, the geoip2 and user-agents dependencies, and GeoLite2-City.mmdb for GeoIP enrichment.

Source text

SKILL.md · Apache-2.0
---
name: analyzing-web-server-logs-for-intrusion
description: Parse Apache and Nginx access logs to detect SQL injection attempts,
  local file inclusion, directory traversal, web scanner fingerprints, and brute-force
  patterns. Uses regex-based pattern matching against OWASP attack signatures, GeoIP
  enrichment for source attribution, and statistical anomaly detection for request
  frequency and response size outliers.
domain: cybersecurity
subdomain: security-operations
tags:
- web-log-analysis
- apache-logs
- nginx-logs
- sql-injection-detection
- lfi-detection
- directory-traversal
- intrusion-detection
version: '1.0'
author: mahipal
license: Apache-2.0
nist_csf:
- DE.CM-01
- RS.MA-01
- GV.OV-01
- DE.AE-02
mitre_attack:
- T1190
- T1059.007
- T1110
- T1595.002
- T1505.003
---


# Analyzing Web Server Logs for Intrusion


## When to Use

- When investigating security incidents that require analyzing web server logs for intrusion
- When building detection rules or threat hunting queries for this domain
- When SOC analysts need structured procedures for this analysis type
- When validating security monitoring coverage for related attack techniques

## Prerequisites

- Familiarity with security operations concepts and tools
- Access to a test or lab environment for safe execution
- Python 3.8+ with required dependencies installed
- Appropriate authorization for any testing activities

## Instructions

1. Install dependencies: `pip install geoip2 user-agents`
2. Collect web server access logs in Combined Log Format (Apache) or Nginx default format.
3. Parse each log entry extracting: IP, timestamp, method, URI, status code, response size, user-agent, referer.
4. Apply detection rules:
   - SQL injection: `UNION SELECT`, `OR 1=1`, `' OR '`, hex encoding patterns
   - LFI/Path traversal: `../`, `/etc/passwd`, `/proc/self`, `php://filter`
   - XSS: `<script>`, `javascript:`, `onerror=`, `onload=`
   - Scanner signatures: nikto, sqlmap, dirbuster, gobuster, wfuzz user-agents
   - Brute force: >50 POST requests to login endpoints from same IP in 5 minutes
5. Enrich with GeoIP data and generate a prioritized findings report.

```bash
python scripts/agent.py --log-file /var/log/nginx/access.log --geoip-db GeoLite2-City.mmdb --output web_intrusion_report.json
```

## Examples

### Detect SQLi in URI
```
192.168.1.100 - - [15/Jan/2024:10:30:45 +0000] "GET /products?id=1' UNION SELECT username,password FROM users-- HTTP/1.1" 200 4532
```

### Scanner User-Agent Detection
```
Nikto/2.1.6, sqlmap/1.7, DirBuster-1.0-RC1, gobuster/3.1.0
```

© mahipal · Apache-2.0 · mukul975/Anthropic-Cybersecurity-Skills

Similar skills

All skills for Security →

From the same set90

performing-web-application-vulnerability-triage Triages SAST and DAST scanner findings, filters false positives, and calculates OWASP risk scores. It helps teams prioritize fixes and cut alert fatigue. CX Codex +1 433installs analyzing-cobaltstrike-malleable-c2-profiles Parses Cobalt Strike Malleable C2 profiles and extracts network indicators for detection rules. Use it when examining a profile or validating Beacon traffic. CX Codex +1 426installs analyzing-network-traffic-of-malware Walks through a malware PCAP to find C2 protocols, exfiltration channels and payload downloads. Useful for sandbox runs and live incident response. CX Codex +1 413installs analyzing-malicious-url-with-urlscan This skill walks through scanning suspicious and phishing URLs with URLScan.io and pulling the screenshot, DOM, redirect chain and IOCs out of the report. CX Codex +1 411installs analyzing-cobalt-strike-beacon-configuration This skill extracts Cobalt Strike Beacon configuration from PE files and memory dumps. Use it to inspect C2 infrastructure, malleable C2 settings, and operator clues. CX Codex +1 404installs analyzing-ethereum-smart-contract-vulnerabilities Runs static and symbolic analysis on Solidity smart contracts using Slither and Mythril. Catches reentrancy, integer overflows, and access flaws before deployment. CX Codex +1 393installs analyzing-malicious-pdf-with-peepdf This skill statically inspects suspicious PDFs with peepdf, pdfid.py, and pdf-parser.py. Use it to triage attachments, inspect exploit documents, and collect detection indicators. CX Codex +1 387installs testing-api-for-mass-assignment-vulnerability Tests APIs for mass assignment by adding undocumented request fields and checking whether they persist. Use it for profile, registration, and object-creation endpoints. CX Codex +1 385installs

Project sponsors

Companies that keep this analytics open
Gold sponsor

Impressions, clicks and code copies — open statistics. We keep the numbers public for the same reason NeBlask itself is public. Become a sponsor