Analyzing webshells

From meltedinhex/analyst-ai-pack · View interactive version

Analyzing webshells is an AI agent skill from the GitHub repository meltedinhex/analyst-ai-pack. Analyzes suspected webshells (PHP, ASPX/ASP, JSP) by detecting dynamic-execution sinks, input-to-sink data flow, and common encoder/obfuscation chains, then decoding obvious layers to reveal the command interface. Activates for requests to analyze a webshell, identify a PHP/ASPX/JSP backdoor, or deo

How to use this skill

Skill file

Analyzing Webshells

When to Use

it is a webshell and understand its command interface.

Do not use a live web server to execute the script to "test" it — that runs attacker code.

Analyze the source statically.

Prerequisites

Safety & Handling

Workflow

Step 1: Detect execution sinks and input flow

python scripts/analyst.py scan shell.php

Flags dynamic-execution sinks (eval, assert, system, exec, passthru, Runtime.exec,

ASPX eval()/Process.Start) and whether request input ($_GET/$_POST/Request) reaches them.

Step 2: Identify obfuscation/encoder chains

Detects base64_decode, gzinflate, str_rot13, eval(chr(...)), hex \x strings, and

FromBase64String chains commonly wrapping the payload.

Step 3: Decode obvious layers

Apply base64/rot13/gzinflate where present to reveal the inner command interface (best-effort,

non-executing).

Step 4: Classify and report

Note the language, the password/parameter gate (if any), and capabilities (file manager, command

exec, SQL, upload); defang IOCs.

Validation

Pitfalls

References

Use this skill with your AI agent: Open on Skill Issue to copy, download, or add to your library. Works with Claude, ChatGPT, Gemini, Cursor, Windsurf and more.