security-vite

Audit Vite applications for environment exposure and dev server misconfigurations.

7|2|Updated Jan 18, 2026
One-click install
npx skills add https://github.com/jal-co/jalco-opencode --skill security-vite-jal-co
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: security-vite
Source: https://github.com/jal-co/jalco-opencode/tree/main/opencode/.config/opencode/skills/security-vite
Command: npx skills add https://github.com/jal-co/jalco-opencode --skill security-vite-jal-co

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill requires ripgrep, and includes scripts (resource) components.

What problem does it solve?

Audits Vite-based applications to uncover environment exposure, insecure build configurations, and dev-server misconfigurations that could leak secrets or introduce security risks.

Core Features & Use Cases

  • Detects VITE_ prefixed variables exposed to the client and flags unsafe usage.
  • Checks Vite build and dev server configurations (host binding, proxy setups, and source maps) for potential exposure.
  • Provides remediation guidance and best practices for secure Vite setups in SPAs.

Quick Start

Run the VITE security scan on your project directory to identify exposed vars, insecure configs, and potential leaks.

Frequently Asked Questions about security-vite

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

FAQPage Schema
How do I audit my Vite app for exposed environment variables and secrets?

To audit a Vite app for environment exposure, scan the project directory to detect VITE_ prefixed variables exposed to the client, identify build-time secrets, and flag unsafe usage. This process checks configurations and provides remediation guidance to secure your setup.

What Vite dev server misconfigurations can cause security risks?

Vite dev server security risks often stem from insecure host binding, improper proxy setups, and exposed source maps. Auditing your Vite configuration detects these misconfigurations, preventing potential secret leaks and unauthorized access during local development.

How do I check if my Vite config is exposing secrets to the client?

Check for secret exposure by analyzing your Vite.config.ts usage and environment variable handling. An automated scan identifies VITE_ prefixed variables sent to the browser, verifies safe defaults, and flags insecure build-time secret management.

Do I need ripgrep installed to scan my Vite project for security issues?

Yes, you need ripgrep installed as a dependency to perform static analysis on your Vite project. It enables the scanner to efficiently search through source code and configuration files to detect environment exposure and insecure setups.

What is the best way to secure environment variables in a Vite SPA?

The best way to secure environment variables in a Vite SPA is to validate Vite.config.ts usage, ensure safe defaults, and avoid exposing VITE_ prefixed secrets. Automated auditing detects leaks and provides clear remediation steps for static analysis.

Why does my Vite build expose sensitive environment variables to the browser?

Your Vite build exposes sensitive environment variables because VITE_ prefixed variables are intentionally injected into the client bundle. Auditing your environment variable handling identifies these exposed variables and provides remediation steps to remove them.