security

Identify and remediate security vulnerabilities in code and infrastructure.

Updated Mar 3, 2026
One-click install
npx skills add https://github.com/GuyErreich/PersonalWebsite --skill security-guyerreich
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: security
Source: https://github.com/GuyErreich/PersonalWebsite/tree/main/.github/skills/security
Command: npx skills add https://github.com/GuyErreich/PersonalWebsite --skill security-guyerreich

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Identify and remediate security vulnerabilities in code, configurations, and data flows to prevent injections, auth weaknesses, and data exposure.

Core Features & Use Cases

  • Prevention of SQL injection via parameterized queries in databases (Supabase, PostgreSQL) and ORM equivalents.
  • Prevent XSS and CSRF through proper input sanitization, React escaping, DOMPurify, origin checks, and CSRF tokens.
  • Strengthen authentication and token security, including safe API key handling, secure cookies, and session validation.
  • Validate and sanitize inputs on the server, enforce strict allowlists, and avoid exposing internal errors.
  • Protect sensitive data at rest and in transit, enforce HTTPS and encryption, and apply secure file uploads.
  • Audit and harden API integrations by validating external responses against schemas.

Quick Start

Audit your codebase for injection and data-exposure risks, then implement the secure patterns described to reduce vulnerabilities.

Frequently Asked Questions about security

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

FAQPage Schema
How do I prevent SQL injection in Supabase and PostgreSQL queries?

Prevent SQL injection by using parameterized queries in Supabase and PostgreSQL or ORM equivalents. Parameterized queries separate SQL logic from user input, ensuring that data is treated strictly as data rather than executable code, which stops injection attacks.

What is the best way to sanitize user input and prevent XSS in React applications?

The best way to prevent XSS in React is through proper input sanitization, native React escaping, and DOMPurify. Sanitizing user inputs on the server and enforcing strict allowlists ensures that malicious scripts are stripped before rendering content in the DOM.

How do I secure authentication tokens and handle API keys safely?

Secure authentication by enforcing safe API key handling, HTTP-only cookies, and strict session validation. Storing tokens in HTTP-only cookies prevents client-side scripts from accessing sensitive session data, reducing the risk of token theft via XSS.

Does my application need CSRF protection and origin checks for API integrations?

Yes, your application needs CSRF protection and origin checks to harden API integrations. Implementing CSRF tokens alongside origin validation ensures that external requests are legitimate, preventing unauthorized state-changing actions from malicious origins.

How do I protect sensitive data at rest and secure file uploads?

Protect sensitive data at rest and in transit by enforcing HTTPS and encryption across your infrastructure. Apply secure file upload protocols and validate external responses against strict schemas to prevent data exposure and malicious file payloads.

Why should I validate external API responses against schemas during code reviews?

Validate external API responses against schemas during code reviews to harden API integrations and avoid exposing internal errors. Schema validation ensures that incoming data strictly matches expected formats, preventing unexpected data flows from compromising your application logic.