ai-code-scanner

v0.5.1
io.github.GuardBee/ai-code-scanner Checked 1 hour ago Published 1 month ago

Scans code for insecure LLM/AI integration: exposed keys, unsafe output, prompt injection

These tools were reported by the server itself during our smoke test (tools/list), not copied from the README.

scan_text

Scan a text string or code snippet for insecure AI/LLM integration patterns (client-exposed keys, unsafe output handling, excessive agent tool permissions, PII sent to a model, prompt injection surface).

ParameterTypeDescription
content *stringThe code content to scan
labelstringOptional label shown in findings (e.g. filename)

scan_file

Scan a single file for insecure AI/LLM integration patterns

ParameterTypeDescription
path *stringAbsolute or relative path to the file to scan

scan_directory

Recursively scan a directory for insecure AI/LLM integration patterns. Automatically skips node_modules, .git, dist, and binary files.

ParameterTypeDescription
path *stringAbsolute or relative path to the directory to scan
excludearraySkip files/dirs whose path contains one of these strings
includearrayOnly scan files whose path contains one of these strings (e.g. [".ts", "src/agents"])
maxFilesintegerMaximum number of files to scan (default: 5000)

list_patterns

List all AI/LLM security patterns that the scanner can detect, grouped by category (including any custom rules loaded from .guardbee/rules)