prototype-pollution

Detect prototype pollution via __proto__ and constructor.prototype merge paths.

5|2|Updated May 16, 2026
One-click install
npx skills add https://github.com/DorianGallo/hack-skills-local --skill prototype-pollution-doriangallo
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: prototype-pollution
Source: https://github.com/DorianGallo/hack-skills-local/tree/main/skills/prototype-pollution
Command: npx skills add https://github.com/DorianGallo/hack-skills-local --skill prototype-pollution-doriangallo

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

This Skill helps you find and validate prototype pollution when untrusted input is merged into objects in JavaScript applications, preventing unexpected global behavior or security-critical gadget execution.

Core Features & Use Cases

  • Mechanism-focused testing: Explains how prototype chain behavior enables pollution via proto and constructor.prototype.
  • Black-box detection workflow: Provides client-side and server-side probing patterns to confirm persistence and observable side effects across requests.
  • Exploit path guidance: Maps likely post-pollution sinks and gadget scenarios (e.g., template/config-based RCE patterns) to prioritize real impact.

Quick Start

Send a JSON request containing a proto payload to a candidate merge point, then immediately follow with a clean request to verify whether global parsing or unrelated response behavior changes.

Frequently Asked Questions about prototype-pollution

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How does JavaScript prototype pollution work in Nodejs applications?

JavaScript prototype pollution occurs when untrusted keys are merged into objects, mutating shared prototype state via __proto__ or constructor.prototype paths. This allows attacker-controlled parameters to alter global object behavior during query parsing or JSON body handling.

How do I test for prototype pollution in server-side JavaScript APIs?

To test for prototype pollution in server-side JavaScript, send a JSON request containing a __proto__ payload to a candidate merge point, then follow with a clean request to verify if global parsing or unrelated response behavior changes.

What is the best way to detect prototype pollution via object merge utilities?

The best way to detect prototype pollution via object merge utilities is through black-box detection workflows that probe both __proto__ and constructor.prototype paths, validating observable side effects and persistence across subsequent requests.

Can prototype pollution lead to remote code execution in web applications?

Prototype pollution can lead to remote code execution by reaching downstream gadget sinks. Exploit path guidance maps post-pollution sinks, such as template or configuration-based RCE patterns, to prioritize real security impact.

Does prototype pollution testing work for query string parsing vulnerabilities?

Prototype pollution testing works for query string parsing vulnerabilities by checking if web and API stacks consume attacker-controlled parameters during deep assignment or merge operations, mutating shared prototype state globally.