How to Detect CodeBuddy Code and CodeBuddy IDE on Company Laptops

CodeBuddy is Tencent's AI coding assistant. It comes as a terminal agent (CodeBuddy Code, installed from npm) and as a desktop IDE, and both can answer to the command codebuddy. Here is how to tell them apart on each OS, a read-only check, and the settings worth a finding.

By Kuntur team · Published

How to check if CodeBuddy is installed: for the CLI, look for the npm package @tencent-ai/codebuddy-code or a codebuddy-code command. For the IDE, look for /Applications/CodeBuddy.app on a Mac or %LOCALAPPDATA%\Programs\CodeBuddy and an uninstall entry named CodeBuddy on Windows. A codebuddy command alone can be either one.

What CodeBuddy is and why security teams care

CodeBuddy Code is a terminal agent that reads and edits code, runs commands and calls MCP servers with the logged-in user's permissions; CodeBuddy IDE is a desktop editor with the same assistant built in. Both are developed by Tencent and sign in to its service.

Where CodeBuddy leaves traces

SignalWindowsmacOSLinux
CLI npm package@tencent-ai/codebuddy-code under %APPDATA%\npm\node_modulesSame package under npm root -gSame as macOS
CLI commandscodebuddy-code, codebuddy and cbc (all from the npm package)
CLI processnode running @tencent-ai/codebuddy-code
IDE install%LOCALAPPDATA%\Programs\CodeBuddy, uninstall entry CodeBuddy/Applications/CodeBuddy.app-
IDE user data%APPDATA%\CodeBuddy~/Library/Application Support/CodeBuddy-
Settings (CLI)~/.codebuddy/settings.json (user), .codebuddy/settings.json and .codebuddy/settings.local.json (project)
MCP servers (CLI)~/.codebuddy/.mcp.json (also the older ~/.codebuddy/mcp.json and ~/.codebuddy.json); .mcp.json in a project

Trap: the npm package adds a codebuddy command, which is also the name of the IDE's launcher, and Homebrew's uninstall of the IDE removes ~/.codebuddy, so that folder is shared too. Kuntur reports the CLI only from codebuddy-code, the npm package or its node process, and the IDE only from its install folder, data folder, process path or uninstall entry. The Windows IDE folder follows the default for per-user Electron apps; the uninstall entry is the more reliable signal.

Check one machine

Both checks only read files and the process table. They send nothing over the network, change nothing, and print paths and labels only, never the contents of a settings or credentials file.

Windows (PowerShell)

# Read-only, no network. Run as the user (not SYSTEM). Prints paths only.

# 1. CodeBuddy Code (CLI): the npm package and its commands
Test-Path "$env:APPDATA\npm\node_modules\@tencent-ai\codebuddy-code"
Get-Command codebuddy-code, codebuddy, cbc -ErrorAction SilentlyContinue | Select-Object Source

# 2. CodeBuddy IDE: per-user install folder, user data and the uninstall entry
Test-Path "$env:LOCALAPPDATA\Programs\CodeBuddy"
Test-Path "$env:APPDATA\CodeBuddy"
Get-ItemProperty 'HKCU:\Software\Microsoft\Windows\CurrentVersion\Uninstall\*',
                 'HKLM:\Software\Microsoft\Windows\CurrentVersion\Uninstall\*' -ErrorAction SilentlyContinue |
  Where-Object { $_.DisplayName -match '^CodeBuddy( |$)' } | Select-Object DisplayName, DisplayVersion

# 3. Running now? CLI under node, IDE from its install folder
Get-CimInstance Win32_Process |
  Where-Object { $_.CommandLine -like '*@tencent-ai\codebuddy-code*' -or $_.ExecutablePath -like '*\Programs\CodeBuddy\*' } |
  Select-Object ProcessId, Name, ExecutablePath

# 4. Settings and MCP files, and the settings worth a finding (labels only, no values)
$d = "$env:USERPROFILE\.codebuddy"
foreach ($f in "$d\settings.json", "$d\.mcp.json", "$d\mcp.json", "$env:USERPROFILE\.codebuddy.json") {
  if (Test-Path $f) { $f }
}
$s = "$d\settings.json"
if (Test-Path $s) {
  if (Select-String -Path $s -Pattern '"defaultMode"\s*:\s*"bypassPermissions"' -Quiet) { "  defaultMode bypassPermissions" }
  if (Select-String -Path $s -Pattern '"enableAllProjectMcpServers"\s*:\s*true' -Quiet) { "  enableAllProjectMcpServers true" }
}

macOS and Linux (bash)

# Read-only, no network. Run as the user. Prints paths only.

# 1. CodeBuddy Code (CLI): the npm package and its commands
ls -d "$(npm root -g 2>/dev/null)/@tencent-ai/codebuddy-code" 2>/dev/null
command -v codebuddy-code codebuddy cbc   # "codebuddy" can also be the IDE launcher

# 2. CodeBuddy IDE: app bundle and user data (macOS)
ls -d /Applications/CodeBuddy.app "$HOME/Applications/CodeBuddy.app" 2>/dev/null
ls -d "$HOME/Library/Application Support/CodeBuddy" 2>/dev/null

# 3. Running now? CLI under node, IDE from its bundle
pgrep -fl '@tencent-ai/codebuddy-code|CodeBuddy\.app/'

# 4. Settings and MCP files, and the settings worth a finding (labels only, no values)
for f in "$HOME/.codebuddy/settings.json" "$HOME/.codebuddy/.mcp.json" \
         "$HOME/.codebuddy/mcp.json" "$HOME/.codebuddy.json"; do
  [ -f "$f" ] && echo "$f"
done
s="$HOME/.codebuddy/settings.json"
if [ -f "$s" ]; then
  grep -Eq '"defaultMode"[[:space:]]*:[[:space:]]*"bypassPermissions"' "$s" && echo "  defaultMode bypassPermissions"
  grep -Eq '"enableAllProjectMcpServers"[[:space:]]*:[[:space:]]*true' "$s" && echo "  enableAllProjectMcpServers true"
fi

With nvm, fnm or Volta each Node version has its own global packages, so also list ~/.nvm/versions/node/*/lib/node_modules/@tencent-ai.

Settings worth a finding

SettingWhat it meansWhat Kuntur reports
permissions.defaultMode: "bypassPermissions"Tool calls run without asking by defaultAGENT_PERMISSIONS_BYPASS (user and project settings, unless disableBypassPermissionsMode is "disable")
-y / --dangerously-skip-permissionsThe same for one runA flag: only EDR process command lines show it
enableAllProjectMcpServers: trueEvery MCP server a cloned repository declares is approvedNot a finding yet
Servers in .mcp.jsonPrograms or URLs the agent can call, often with tokens in envMCP inventory and MCP findings

For administrators, CodeBuddy documents permissions.disableBypassPermissionsMode: "disable", which turns bypass mode off, and permissions.disableAutoMode.

Find it across a fleet

The commands above answer the question for one laptop. Across a fleet, run the same read-only checks from the management tool you already use and collect one line per device. These guides show how to deploy a read-only script and read the results; their ready-made scripts cover the most common AI tools, so paste the CodeBuddy checks from this page into the same script:

MDM scripts usually run as SYSTEM or root, where %USERPROFILE% and ~ point at the wrong home folder, so loop over every profile under C:\Users, /Users or /home and replace the home path in each check. The Kuntur agent already does this for CodeBuddy on every endpoint.

How to restrict CodeBuddy with Intune or Jamf

Kuntur does not block, restrict or uninstall anything. If your policy says the CodeBuddy IDE should not run, the restriction is done with your MDM, and the inventory tells you who the rule will affect before you enforce it.

The CLI runs under node, so a binary rule does not catch it (see restricting a terminal agent with Intune for why). If the CLI is approved, distribute a settings.json with permissions.disableBypassPermissionsMode set to disable.

How Kuntur detects CodeBuddy

Kuntur's catalog has two rules: CodeBuddy Code (CLI) by the npm package, the codebuddy-code command and a node process running the package; CodeBuddy IDE by its install folder or app bundle, user data, process path and uninstall entry. The agent also reads the CLI's MCP files (~/.codebuddy/.mcp.json and the older names) for every user profile, and treats MCP servers started by the IDE as the IDE's.

To check one machine now, the free Kuntur scanner lists CodeBuddy together with every other AI tool, extension, local model and MCP server it finds:

  1. Download scan.ps1.
  2. Read it. It's plain text; here's what it does.
  3. Check its SHA-256 against the published hash: Get-FileHash .\scan.ps1 -Algorithm SHA256
  4. Run it: powershell -ExecutionPolicy Bypass -File .\scan.ps1

Windows shortcut, if you trust the source (PowerShell)

irm https://app.kuntur.io/scan.ps1 | iex

macOS and Linux (Terminal)

curl -fsSL https://app.kuntur.io/scan.sh | sh

It needs no account and no admin rights, writes an HTML report to the Desktop (or home folder) and uploads nothing. You can read scan.ps1 or scan.sh before running it; what it collects is documented.

Across a fleet, the Kuntur agent reports the same inventory for every user profile on Windows, macOS and Linux. You mark CodeBuddy approved or unauthorized once for the organization, the dashboard shows which machines carry it, and every decision lands in an audit log.

Free for up to 5 endpoints. Pro is US$3 per endpoint per month (or US$30 per endpoint per year) for 10 to 30 endpoints. The trial needs no credit card. Kuntur detects and reports; it does not block or uninstall anything.

FAQ

Where is CodeBuddy Code installed?
As the global npm package @tencent-ai/codebuddy-code, which adds the commands codebuddy-code, codebuddy and cbc. Its settings are in ~/.codebuddy/settings.json.
How do I tell the CodeBuddy CLI from the IDE?
The CLI is the npm package and runs under node; the IDE is CodeBuddy.app on a Mac or %LOCALAPPDATA%\Programs\CodeBuddy on Windows. Do not rely on the codebuddy command or the ~/.codebuddy folder, which both can use.
Does CodeBuddy have a YOLO or bypass mode?
Yes: the bypassPermissions permission mode, selected with -y / --dangerously-skip-permissions or permissions.defaultMode. Administrators can disable it with permissions.disableBypassPermissionsMode: "disable".
Where does CodeBuddy store MCP servers?
In ~/.codebuddy/.mcp.json for the user (older installs: ~/.codebuddy/mcp.json or ~/.codebuddy.json) and .mcp.json at a project's root.

Sources

  1. CodeBuddy Code permission modes (bypassPermissions)
  2. CodeBuddy Code settings files
  3. CodeBuddy Code MCP configuration
  4. Homebrew cask codebuddy (IDE paths)
  5. @tencent-ai/codebuddy-code on npm

Detect other AI tools:

Related guides: