AribotDevelopers Sign in

Aribot for VS Code

Aribot is a threat modeling and security assurance platform by Ayurak. This extension brings your company's Aribot data into VS Code:

ext install aristiun.aribot-security

You need an Aribot account and an API key.

<!-- TODO: add screenshots (Threats view, a finding with its hover, the gate preview) once they are captured from a real workspace. -->

Sign in

  1. In Aribot, create an API key (Company Admin > Developer & API).
  2. In VS Code, open the Command Palette and run Aribot: Sign in.
  3. Paste the key. It is stored in VS Code secret storage, which uses your operating system's credential store where one is available. It is never written to settings.json.

To remove the key, run Aribot: Sign out.

If you used version 2 with a key in settings.json, the extension moves it to secret storage on first start and deletes it from your settings. A key found only in a workspace's .vscode/settings.json is used only after you confirm it is yours, and it is removed from that file either way.

Features

Diagram threat scan

Right-click a diagram (.drawio, .png, .jpg, .jpeg, .vsdx, .vsd) in the Explorer and choose Aribot: Scan Diagram for Threats, or run the command from the Command Palette. Aribot uploads the file, analyses it on the server and shows its threats in the Threats view, grouped under the diagram with severity, component, description and mitigations.

Aribot: Choose Diagram lists the diagrams your company already has in Aribot and opens one in the Threats view.

File feedback in the editor

Set aribot.gateConfigId to the gate configuration of your repository's application in Aribot. When you open or save a file, Aribot shows findings from your company's rules as diagnostics on the affected lines. Hover a finding to see the rule, the related threat and component, the security requirements and why it matters.

If Aribot does not know a file yet, you see one message asking you to link the repository to an application in Aribot.

Gate preview

The status bar shows how many warnings the IDE gate reports for your changed files. Click it, or run Aribot: Check My Changes (Gate Preview), to check again. The IDE gate only warns; pull requests are checked separately by your pipeline.

Fixes

On a finding, the light bulb offers:

Compliance

Aribot: Run Compliance Scan scans the selected diagram's components against your company's compliance policies, optionally limited to AWS, Azure or Google Cloud components. The Compliance view lists the stored scans of the diagram with their scores. Opening the view does not start a scan.

Dashboard

The Dashboard view and the status bar show your company's diagram, threat and critical threat counts. While Aribot is still summarising some diagrams, the view says so, and the threat totals cover only the summarised ones.

Commands

CommandWhat it does
Aribot: Sign inStores your API key in secret storage
Aribot: Sign outDeletes the key from secret storage
Aribot: Scan Diagram for ThreatsUploads a diagram and shows its threats
Aribot: Choose DiagramOpens one of your company's diagrams in the Threats and Compliance views
Aribot: Run Compliance ScanRuns a compliance scan of the selected diagram
Aribot: Show DashboardOpens the Dashboard view
Aribot: RefreshReloads the views and the status bar
Aribot: Check My Changes (Gate Preview)Asks the IDE gate about your changed files

Settings

SettingDefaultDescription
aribot.baseUrlhttps://aribot.ayurak.comAddress of the Aribot server, host only. User settings only: a workspace cannot change it. Must use https (http is accepted for localhost). For a host outside *.ayurak.com you are asked once, per host, before your key is sent there.
aribot.gateConfigId0Gate configuration id of the repository's application in Aribot. 0 turns file feedback and the gate preview off.
aribot.fileFeedbacktrueAsk Aribot about each file you open or save (when a gate configuration is set).
aribot.autoScanfalseUpload a diagram for threat analysis each time you save it in VS Code.
aribot.apiKeyNo longer used. A key found here is moved to secret storage and removed.

Privacy: what is sent to Aribot

Every request goes to aribot.baseUrl over HTTPS with your API key in the X-API-Key header.

The extension sends no telemetry. Redirects are not followed, so your key is sent only to the configured host. Failed GET requests are retried at most twice; other requests are never repeated, so an upload or a fix request runs once.

Workspace trust

In an untrusted workspace the extension:

Commands you run yourself, such as a diagram scan, still work. The views load when you click Load from Aribot.

aribot.baseUrl can only be set in user settings, so a cloned repository cannot point your key at another server.

Troubleshooting

"You are not signed in": run Aribot: Sign in.

"Aribot did not accept your API key": the key is expired or was revoked. Create a new key in Aribot and sign in again.

"Your company has no licence for ...": the feature named in the message is not enabled for your company. Ask your company admin, or request access from the page the Open Aribot button opens.

"Aribot refused this request": the key's user has no access to that diagram, company or action, or the key is limited to other API paths.

"... was redirected": aribot.baseUrl points at an address that redirects. Set it to the final address, for example https://aribot.ayurak.com.

No findings appear in the editor: check that aribot.gateConfigId is set, that the workspace is trusted, and that the repository is linked to an application in Aribot. The Aribot output channel lists failed requests.

The diagram scan says it is still analysing: large diagrams take longer. Run Aribot: Refresh later; the analysis continues on the server.

For maintainers

Build and test locally:

sh
npm ci --ignore-scripts
npm run compile
npm test
npx vsce package --no-dependencies

Releases are published by .github/workflows/release.yml when a tag v<version> is pushed. The tag must match version in package.json. The publish job runs in the protected GitHub environment vscode-marketplace and waits for a reviewer's approval.