security-bun

Scan Bun runtime code for unsafe patterns and output remediation guidance.

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

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes scripts (resource) components.

What problem does it solve?

Bun security auditing patterns identify and mitigate risks in Bun runtime applications, focusing on common misconfigurations and unsafe patterns to reduce attack surface.

Core Features & Use Cases

  • Comprehensive vulnerability patterns for Bun runtime apps, including shell escaping, command execution, Bun.spawn risks, Bun.file path handling, and WebSocket security considerations.
  • Practical guidance with examples and a hardening checklist to help engineers audit and remediate issues in existing Bun services (Bun.serve, Bun.spawn, Bun.file, etc.).
  • Use Case: Security engineers can audit a Bun-based API or service to validate input handling and authentication before deployment.

Quick Start

Run the Bun security audit against a target project to identify unsafe patterns and apply the recommended mitigations.

Frequently Asked Questions about security-bun

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

FAQPage Schema
How do I audit a Bun application for security vulnerabilities?

To audit a Bun application for security vulnerabilities, run a static analysis scan against your TypeScript or JavaScript server code to detect unsafe patterns in Bun.serve, Bun.spawn, and Bun.file APIs.

What security risks does Bun.spawn introduce in server applications?

Bun.spawn introduces shell injection and command execution risks in server applications if user input is not properly escaped. Static analysis detects shell escaping misuse to mitigate these vulnerabilities.

How does path traversal affect Bun.file API usage?

Path traversal affects Bun.file API usage when unsanitized input constructs file paths, allowing unauthorized file access. Security auditing identifies unsafe path handling patterns and provides remediation guidance.

Can I check my Bun WebSocket implementation for missing authentication?

Yes, you can check your Bun WebSocket implementation for missing authentication by scanning the codebase for unbounded requests and unauthenticated WebSocket workflows to ensure secure runtime access.

Does static analysis detect SQL injection risks in Bun runtimes?

Yes, static analysis detects SQL injection risks in Bun runtimes by scanning code for unsafe query construction patterns and providing actionable guidance aligned with a hardening checklist.

What are the limitations of static analysis for Bun security auditing?

Static analysis for Bun security auditing is limited to detecting known unsafe code patterns like shell escaping and path traversal; it cannot identify runtime vulnerabilities or complex logic flaws.