IDE Support
Real-time vulnerability scanning, inline Package Firewall checks, and AI-assisted remediation for VS Code, Cursor, and JetBrains IDEs.
IDE Support
Safeguard ships an IDE extension for VS Code and Cursor, and a separate plugin for JetBrains IDEs. Both scan your dependency manifests as you work, surface vulnerabilities inline, and offer AI-assisted fixes without leaving the editor. They're independently built and versioned, so feature coverage differs slightly between the two — this page calls out where.
Supported IDEs
| IDE | Distribution | Current version |
|---|---|---|
| VS Code | VS Code Marketplace | 5.1.0 (requires VS Code ^1.85.0) |
| Cursor | Open VSX Registry — same extension package as VS Code | 5.1.0 |
| JetBrains IDEs (IntelliJ IDEA, PyCharm, WebStorm, PhpStorm, Rider, GoLand, RubyMine, CLion, DataGrip, Android Studio) | JetBrains Marketplace | 1.7.1, requires IDE 2023.3 or later and JDK 17+ |
The VS Code/Cursor extension and the JetBrains plugin are separate codebases with independent release cadences and version numbers — a version bump on one doesn't imply anything about the other.
Installation
VS Code
code --install-extension Safeguard-sh-Inc.SafeguardshIdeExtensionOr open Extensions (Ctrl+Shift+X / Cmd+Shift+X), search "Safeguard", and click Install.
Cursor
Cursor installs through Open VSX rather than the VS Code Marketplace:
cursor --install-extension Safeguard-sh-Inc.SafeguardshIdeExtensionOr open Extensions in Cursor, search "Safeguard", and click Install.
JetBrains IDEs
- Open Settings/Preferences → Plugins.
- Search "Safeguard" and click Install.
- Restart the IDE.
You can also download the plugin ZIP from the JetBrains Marketplace page and install it via the gear icon → Install Plugin from Disk.
Authentication
Both the extension and the plugin authenticate with OAuth 2.0 device flow — there's no manual tenant ID entry required.
- Run Safeguard: Login (Command Palette in VS Code/Cursor, or Tools → Safeguard → Login in JetBrains).
- A browser tab opens at
app.safeguard.sh/activateshowing a verification code. - Sign in and approve the device.
- Return to the IDE — your tenant ID is populated automatically and tokens are stored in the IDE's secure/encrypted credential storage.
Device codes expire after a fixed window (10 minutes per the extension's own documentation) — if authentication times out, just re-run Safeguard: Login. Public-package scanning works without logging in; some backend-dependent features require it — backend-verified Package Firewall verdicts (safeguard.packageFirewallUseBackend) and backend-sourced notifications (safeguard.surfaceBackendNotifications) are silently disabled or fall back to local/offline behavior when you aren't logged in.
The activation link carries the device code and IDE type as query parameters, for example:
https://app.safeguard.sh/activate?device_code=abc123&user_code=WXYZ&ide_type=vscodeYou can copy this URL out of the login notification and open it on another machine or browser profile if the one the IDE launched isn't where you're signed in — approving it there completes authentication back in the original IDE. You can also be logged in on multiple IDE instances or devices at once: each holds its own token, so logging out of one doesn't affect the others.
Run Safeguard: Logout (or Tools → Safeguard → Logout in JetBrains) to clear stored credentials from the IDE's secure storage.
Supported package managers
Both the VS Code/Cursor extension and the JetBrains plugin scan the same manifest families:
| Ecosystem | Package manager | Manifest files |
|---|---|---|
| JavaScript/Node.js | npm, Yarn, pnpm | package.json, package-lock.json, yarn.lock |
| Python | pip, Poetry, Pipenv | requirements.txt, pyproject.toml, Pipfile |
| Java/JVM | Maven, Gradle | pom.xml, build.gradle, build.gradle.kts |
| Go | Go Modules | go.mod, go.sum |
| Rust | Cargo | Cargo.toml, Cargo.lock |
| Ruby | Bundler | Gemfile, Gemfile.lock |
In VS Code/Cursor, the presence of any of package.json, requirements.txt, pom.xml, go.mod, Cargo.toml, or Gemfile in your workspace activates the extension automatically.
Manual scanning
Both autoScan and scanOnSave default to on, but you can trigger a scan on demand:
- VS Code/Cursor: open the Command Palette (
Ctrl+Shift+P/Cmd+Shift+P) and run Safeguard: Scan Project for Vulnerabilities (Ctrl+Shift+V/Cmd+Shift+V) for the whole workspace, Safeguard: Scan Current File for the open manifest, or Safeguard: Scan Selected Code for Vulnerabilities for a highlighted block. - JetBrains: right-click a manifest file in the project tree and choose Safeguard → Scan File for Vulnerabilities, or use Tools → Safeguard → Scan Project for the whole project.
Viewing scan results
- VS Code/Cursor: open the Safeguard view from the activity bar for the Vulnerabilities, SBOM, Compliance, and Recommendations panels, or hover a flagged dependency inline for a quick summary and lightbulb fix. Right-click any panel and choose Export Report to save findings for an audit.
- JetBrains: open the Safeguard tool window (bottom panel) for a hierarchical vulnerability tree — expand a package to see its individual CVEs, and double-click one for full CVSS/CWE details. Vulnerable lines are also highlighted inline, color-coded by severity (red/critical, orange/high, yellow/medium, blue/low); hovering one shows a quick summary.
Package Firewall inline checks (VS Code / Cursor)
As you edit a manifest file, the extension checks each dependency you add against Safeguard's Package Firewall and flags anything that would be warned on or blocked — before you ever run install. This is a lighter-weight, editor-native companion to the install-time proxy described in Package Firewall; it evaluates the package name as you type it rather than intercepting a real install.
It catches three things:
- Typosquats — a name one or two edits away from a popular package (for example
expresinstead ofexpress) triggers a "did you mean…" suggestion. - Dependency / namespace confusion — a scoped package that shadows a popular unscoped name under an unrecognized scope is flagged.
- Known-malicious packages — names matching documented malicious packages are blocked inline.
Flags appear as ⛔/⚠ badges next to the dependency line, with a hover card and a full verdict in the details panel — the same annotation surface used for vulnerability findings.
Two settings control it:
| Setting | Default | Effect |
|---|---|---|
safeguard.enablePackageFirewall | true | Turns inline Package Firewall checks on or off. |
safeguard.packageFirewallUseBackend | false | When enabled, queries Safeguard's backend for verdicts (requires login). When disabled, an offline local heuristic runs entirely client-side. |
This feature is documented for the VS Code/Cursor extension only. The JetBrains plugin's published documentation does not mention inline Package Firewall checks.
To require backend-verified verdicts (rather than the offline heuristic) for every dependency you add, set this in settings.json:
{
"safeguard.enablePackageFirewall": true,
"safeguard.packageFirewallUseBackend": true
}Note that packageFirewallUseBackend requires you to be logged in — see Authentication.
AI-powered remediation
Both the extension and the plugin generate fix suggestions via one of three remediation strategies, set with safeguard.remediationStrategy (VS Code/Cursor) or the equivalent picker in the JetBrains quick-fix flow:
| Strategy | Behavior |
|---|---|
| Safe | Minor version updates only — minimal risk of breakage. |
| Balanced (default) | Minor and patch updates. |
| Aggressive | Updates to the latest available version. |
-
VS Code/Cursor: hover a flagged dependency, open the lightbulb menu (
Ctrl+./Cmd+.), and choose a suggested fix, or run Safeguard: Auto-Fix Vulnerability (Bump Version) / Safeguard: Fix All Vulnerabilities. You can also set a default strategy insettings.json:{ "safeguard.remediationStrategy": "safe" } -
JetBrains: place the cursor on a flagged dependency, press
Alt+Enter(⌥↩on Mac), select "Fix with Safeguard AI", pick a strategy, and review the change in the diff view before applying. To fix an entire package or project at once, open the Safeguard tool window, right-click the package or project node, and choose Fix All Vulnerabilities.
Interactive AI assistant (VS Code / Cursor)
The extension includes a chat panel (in the Safeguard activity-bar view) for asking security questions in natural language, analyzing selected code, and inserting suggested code at the cursor. Relevant commands and shortcuts:
| Command | Shortcut | Purpose |
|---|---|---|
Safeguard: Open AI Assistant | Ctrl+Shift+S / Cmd+Shift+S | Opens the chat view. |
Safeguard: Ask AI Assistant | Ctrl+Shift+A / Cmd+Shift+A | Quick query using current file/selection as context. |
Safeguard: Analyze Selected Code | Ctrl+Shift+C / Cmd+Shift+C (requires a selection) | Runs a security analysis on the selected code. |
Safeguard: Open Inline Chat | Ctrl+Shift+I / Cmd+Shift+I | Opens chat inline at the cursor. |
Safeguard: New Conversation | Ctrl+L / Cmd+L | Starts a new conversation, clearing prior context. |
Conversation history is tracked automatically, and the commands above let you start fresh, export, or clear a conversation, or insert a suggested snippet at the cursor. Example questions the assistant is designed to answer:
- "Why is this package vulnerable?"
- "What's the safest way to fix CVE-2024-12345?"
- "Should I upgrade React to v19?"
The JetBrains plugin's published documentation describes quick-fix intention actions and a vulnerability tool window, but not an equivalent interactive chat assistant.
Feature comparison
| Feature | VS Code / Cursor | JetBrains |
|---|---|---|
| Real-time manifest scanning | ✅ | ✅ |
| Inline vulnerability warnings | ✅ | ✅ |
| Scan on save / on project open | ✅ | ✅ |
| Package Firewall inline checks | ✅ | Not documented |
| AI remediation (Safe / Balanced / Aggressive) | ✅ | ✅ (via intention actions) |
| Interactive AI chat assistant | ✅ | Not documented |
| SBOM export (CycloneDX / SPDX) | ✅ | Not documented |
| OAuth 2.0 device-flow login | ✅ | ✅ |
Commands reference (VS Code / Cursor)
All commands are registered under the Safeguard category in the Command Palette (Ctrl+Shift+P / Cmd+Shift+P). This is the full list contributed by the extension manifest:
Authentication
| Command |
|---|
Safeguard: Login |
Safeguard: Logout |
Safeguard: Set Tenant ID |
Scanning
| Command |
|---|
Safeguard: Scan Project for Vulnerabilities |
Safeguard: Scan Current File |
Safeguard: Scan Entire File for Vulnerabilities |
Safeguard: Scan Selected Code for Vulnerabilities |
Safeguard: Show Vulnerability Details |
Remediation
| Command |
|---|
Safeguard: Auto-Fix Vulnerability (Bump Version) |
Safeguard: Fix All Vulnerabilities |
Safeguard: Ignore Vulnerability |
Safeguard: Set Remediation Strategy |
AI assistant
| Command |
|---|
Safeguard: Open AI Assistant |
Safeguard: Ask AI Assistant |
Safeguard: Open Inline Chat |
Safeguard: Analyze Selected Code |
Safeguard: New Conversation |
Safeguard: Clear Conversation |
Safeguard: Export Conversation |
Safeguard: Insert Code at Cursor |
SBOM, compliance, and posture
| Command |
|---|
Safeguard: Generate SBOM |
Safeguard: Export SBOM |
Safeguard: Compare SBOM with Previous |
Safeguard: Check Compliance (OWASP, EU AI Act) |
Safeguard: Check Code Quality |
Safeguard: Check Security Posture |
Safeguard: View Dependency Graph |
Other
| Command |
|---|
Safeguard: Check Staged Commit for Secrets — see Secrets Scanning for the underlying capability |
Safeguard: Review Pull Request |
Safeguard: Discover Assets — see Asset Discovery |
Safeguard: Export Security Report |
Safeguard: Open Notifications |
Safeguard: Configure Settings |
This command list comes from the extension's own manifest. The JetBrains plugin does not publish an equivalent full command list — its documented entry points are the Tools → Safeguard menu, the intention-action quick fixes (
Alt+Enter), and the Safeguard tool window described above.
Settings reference (VS Code / Cursor)
Open Settings (Ctrl+, / Cmd+,) and search "Safeguard", or edit settings.json directly.
| Setting | Default | Description |
|---|---|---|
safeguard.authServiceUrl | https://api.safeguard.sh/auth | Auth Service endpoint. Only change for a self-hosted/custom deployment. |
safeguard.dataServiceUrl | https://dev.api.safeguard.sh/data | Data Service endpoint. |
safeguard.goldApiUrl | https://dev.api.safeguard.sh/gpt | AI/remediation service endpoint. |
safeguard.tenantId | "" | Your Safeguard tenant ID. Populated automatically by Safeguard: Login — set manually only if you need to override it. |
safeguard.mcpServerUrl | https://mcp.safeguard.sh | MCP server used for IDE auth and AI features. |
safeguard.notificationServiceUrl | "" | Notification Service endpoint. Leave empty to derive it automatically from the Data Service URL. |
safeguard.autoScan | true | Scan the project automatically on open. |
safeguard.scanOnSave | true | Re-scan manifest files on save. |
safeguard.scanDebounceDelay | 2000 (ms) | Delay before scanning after you stop typing. |
safeguard.showInlineWarnings | true | Show inline decorations for vulnerable dependencies. |
safeguard.showCodeLens | true | Show a CodeLens with fix actions above vulnerable dependencies. |
safeguard.severityThreshold | low | Minimum severity shown (low/medium/high/critical). |
safeguard.includeDevDependencies | true | Include dev dependencies in scans. |
safeguard.enablePackageFirewall | true | Enable inline Package Firewall checks. |
safeguard.packageFirewallUseBackend | false | Use backend verdicts instead of the offline heuristic. |
safeguard.remediationStrategy | balanced | Default fix strategy (safe/balanced/aggressive). |
safeguard.autoFixOnSave | false | Automatically apply fixes on save — off by default; enable with caution. |
safeguard.enableAIAssistant | true | Enable the AI assistant chat features. |
safeguard.showRecommendations | true | Show AI-powered security recommendations. |
safeguard.enableSBOM | true | Enable SBOM generation/tracking. |
safeguard.showDependencyGraph | true | Show the dependency-graph visualization. |
safeguard.enableCompliance | true | Enable compliance-standard checks. |
safeguard.complianceStandards | ["OWASP", "CWE", "NIST"] | Standards checked against. |
safeguard.cacheDuration | 3600000 (ms) | How long scan results are cached (1 hour). |
safeguard.batchSize | 10 | Packages scanned in parallel. |
safeguard.excludePatterns | ["**/node_modules/**", "**/dist/**", "**/build/**"] | Paths excluded from scanning. |
safeguard.notifyOnNewVulnerabilities | true | Notify when new vulnerabilities are detected. |
safeguard.surfaceBackendNotifications | true | Show server-side Safeguard events (critical findings, scan complete, approvals) as native IDE notifications with click-through. Silently disabled when not logged in. |
safeguard.backendNotificationPollSeconds | 60 | How often, in seconds, to poll for new backend notifications (minimum 15). |
safeguard.enableTelemetry | false | Send anonymous usage data — opt-in, off by default. |
A minimal settings.json override for a stricter, self-directed setup — no backend Package Firewall, safe-only fixes, medium+ severity only:
{
"safeguard.remediationStrategy": "safe",
"safeguard.severityThreshold": "medium",
"safeguard.autoFixOnSave": false,
"safeguard.packageFirewallUseBackend": false
}Common errors
Browser doesn't open for login. Copy the activation URL from the notification and open it manually.
"Authentication timeout" / device code expired. Device codes expire after a fixed window; just re-run Safeguard: Login and complete the browser approval before it lapses.
Scan completes with 0 vulnerabilities unexpectedly. Confirm the manifest file is syntactically valid and check that the configured service URLs are reachable, then trigger a manual scan — Safeguard: Scan Project for Vulnerabilities / Scan Current File in VS Code/Cursor, or right-click the file → Safeguard → Scan File for Vulnerabilities in JetBrains. In JetBrains you can also inspect Help → Show Log in Explorer/Finder for scan errors.
JetBrains plugin doesn't appear under Tools after installing. Restart the IDE fully, confirm the plugin's declared IDE-version compatibility under Settings → Plugins → Safeguard, and confirm JDK 17+ is configured under File → Project Structure → SDK.
Package Firewall isn't flagging anything. Confirm safeguard.enablePackageFirewall is true. If you expect backend-sourced verdicts rather than the offline heuristic, also confirm safeguard.packageFirewallUseBackend is true and that you're logged in.
Scans feel slow on a large project. Increase safeguard.cacheDuration (or the equivalent JetBrains cache-duration setting) so repeated scans hit the cache instead of re-querying, disable safeguard.autoScan/scanOnSave in favor of manual scans while doing bulk edits, and confirm the IDE can reach the configured Data Service URL — a slow or blocked network path is a common cause.
"Authentication expired" / "Invalid token" after working for a while. Log out and back in (Safeguard: Logout then Safeguard: Login, or the equivalent Tools → Safeguard menu items in JetBrains) to force a fresh OAuth exchange, and make sure your system clock is synchronized — OAuth tokens are time-sensitive.
Related
- Package Firewall — the install-time proxy and enforcement model the IDE's inline checks are a lightweight companion to.
- Griffin AI — the remediation and assistant engine behind IDE fix suggestions.
- Software Composition Analysis (SCA) — the broader vulnerability/license/malicious-package scanning the IDE extensions surface inline.
- Secrets Scanning — the capability behind the VS Code/Cursor Check Staged Commit for Secrets command.
- Asset Discovery — the capability behind the VS Code/Cursor Discover Assets command.
- SDKs — call the same findings and remediation APIs directly from your own tooling.