Electron secure boundary

From muratgur/ordinus · View interactive version

Electron secure boundary is an AI agent skill from the GitHub repository muratgur/ordinus. Maintain Ordinus Electron security boundaries. Use when changing BrowserWindow options, main/preload/renderer responsibilities, privileged OS access, filesystem/database/process usage, or anything that could expose Electron or Node capabilities to renderer code.

How to use this skill

Skill file

Electron Secure Boundary

Objective

Keep Ordinus secure by preserving the separation between privileged desktop code and UI code.

Rules

Workflow

  1. Identify which side of the boundary the change touches: main, preload, renderer, or shared contracts.
  2. Move privileged behavior to main process services or IPC handlers.
  3. Add the narrowest preload method needed for renderer.
  4. Keep validation and trust decisions in main/shared, not renderer.
  5. Run npm run typecheck, npm run lint, and npm run build.
  6. For boundary changes, smoke test npm run dev or the packaged app.

Red Flags

Use this skill with your AI agent: Open on Skill Issue to copy, download, or add to your library. Works with Claude, ChatGPT, Gemini, Cursor, Windsurf and more.