Escape
Safely formats strings for embedding within common contexts such as regex, shell, SQL, JSON, HTML, or URLs.
escape-mcp is an MCP server that provides a critical utility for developers: safely preparing strings for integration into diverse programming and markup environments. It acts as a shield against common vulnerabilities like injection attacks by intelligently escaping input based on the target context. Whether you're constructing database queries, shell commands, regular expressions, JSON objects, HTML content, or URL parameters, escape-mcp ensures your data is correctly formatted, preventing unintended interpretation and enhancing the security and reliability of your applications without any external dependencies.
主な機能
01Context-specific string escaping for regex, shell, SQL, JSON, HTML, and URL.
02Provides POSIX single-quote wrapping for shell commands.
030 GitHub stars
04Doubles single quotes and wraps strings for SQL injection prevention.
05Backslash-escapes regex metacharacters for safe pattern matching.
06Performs standard JSON stringification and basic HTML entity encoding.
ユースケース
01Preventing injection vulnerabilities in dynamic content generation.
02Safely incorporating user input into backend queries or commands.
03Preparing data for secure display and transmission across different web technologies.