Cursor Privacy Shield
Protect private data before it reaches AI models in Cursor.
Open source · 30-day free trial · Paid license via Lemon Squeezy
Install
From marketplace (recommended)
- Open Cursor or VS Code → Extensions
- Search Cursor Privacy Shield
- Install and reload
From VSIX
git clone https://github.com/speedfenix/cursor-privacy-shield
cd cursor-privacy-shield
npm install && npm run compile && npm run package
Then: Extensions → ... → Install from VSIX → select cursor-privacy-shield-0.1.0.vsix
What it does
Uses Cursor's official Hooks API to intercept data before it reaches LLMs:
| Hook |
Protection |
beforeSubmitPrompt |
Blocks prompts with secrets, API keys, or PII |
beforeReadFile |
Blocks AI from reading .env, keys, secrets/ |
beforeTabFileRead |
Same for Tab completions |
preToolUse |
Denies Read tool on protected paths |
All scanning runs locally. License validation calls Lemon Squeezy only.
Commands
Privacy Shield: Show Status
Privacy Shield: Buy License
Privacy Shield: Enter License Key
Privacy Shield: Scan Workspace for Sensitive Data
Privacy Shield: View Audit Log
Pricing
- 30-day free trial — full features
- After trial — purchase at Lemon Squeezy, enter license key in Cursor
See docs/PAYMENTS.md for store setup.
Configuration
| Setting |
Default |
Description |
privacyShield.enabled |
true |
Master switch |
privacyShield.failClosed |
true |
Block when scanner is down |
privacyShield.blockPromptsWithSecrets |
true |
Block API keys, tokens |
privacyShield.blockPromptsWithPii |
true |
Block email, phone, IBAN |
privacyShield.checkoutUrl |
Lemon Squeezy URL |
Where to buy a license |
Development
npm install
npm run compile
npm test
# Press F5 in VS Code/Cursor to launch Extension Development Host
Publishing
See docs/PUBLISHING.md.
License
MIT with commercial use clause — see LICENSE.
| |