Scan Before You Install: Detecting and Mitigating Local and Composite Vulnerabilities in Skills
Organizations: Stein Faculty of Computer and Information Science, Ben-Gurion University of the Negev, Beer-Sheva, Israel
Abstract
An agent skill packages natural-language instructions, scripts, and reference files that an LLM-based agent loads for a task. Skills may access the file system, shell, and network under user-authorized permissions; weaknesses can lead to unsafe execution. Existing scanners primarily target malicious skills, not unintended vulnerabilities in public repositories, and analyze skills in isolation, overlooking multi-skill interactions. To address these gaps, we developed a six-module scanner: Content Extraction, Local Analysis, Composite Analysis, Validation, Reporting, and Mitigation. Local Analysis detects unintended vulnerabilities in benign skills. On a 556-case leaderboard subset of SkillTrustBench, it achieved 95.90% recall with a 4.22% false positive rate; on a balanced sample of 1,000 MalSkillBench skills, its F1 was 0.947, outperforming Cisco's Skill Scanner, NVIDIA's SkillSpector, AgentSkillsScanner, and SkillSieve. In 1,587 skills from the 75 most-starred GitHub repositories, three analysts confirmed 53 of 59 findings (89.8% precision) across 23 repositories. We developed proof-of-concept (PoC) attacks for each vulnerability, disclosed 10 medium- and high-severity cases to maintainers, and tested mitigations on the remaining cases. Composite Analysis models dependencies among skills through shared resources, invocations, and instruction-mediated interactions. On SCR-Bench, its F1 score was 0.991 (98.7% precision, 99.6% recall), versus 0.816-0.858 for three SkillsGuard configurations released with CompoSkill. It identified two composite findings on GitHub, validated by PoC attacks. The Mitigation module recommends skill substitution, patches, and configuration changes. For 47 of 55 GitHub findings, mitigations prevented PoC attacks in all trials while preserving tested legitimate functionality.
Figures & tables
| Check | Reported | Confirmed | Precision |
|---|---|---|---|
| Value-flow check | 17 | 14 | 82.4% |
| Pattern checks | 2 | 2 | 100.0% |
| Instruction review | 40 | 37 | 92.5% |
| Capability-declaration check | 0 | 0 | – |
| Installation-source check | – | – | – |
| Total | 59 | 53 | 89.8% |
| Confirmed severity | |||||
|---|---|---|---|---|---|
| Threat category | Rep. | Conf. | L | M | H |
| Embedded credentials | 0 | 0 | 0 | 0 | 0 |
| Path traversal | 7 | 5 | 5 | 0 | 0 |
| Server-side request forgery | 3 | 3 | 3 | 0 | 0 |
| Data exfiltration | 7 | 6 | 5 | 0 | 1 |
| Log injection | 0 | 0 | 0 | 0 | 0 |
| Method | TP | FN | FP | TN | Precision (%) | Recall (%) | |
|---|---|---|---|---|---|---|---|
| Our scanner | 665 | 3 | 9 | 648 | 98.7 | 99.6 | 0.991 |
| SG review | 663 | 5 | 214 | 443 | 75.6 | 99.3 | 0.858 |
| SG regex | 551 | 117 | 71 | 586 | 88.6 | 82.5 | 0.854 |
| SG high | 499 | 169 | 56 | 601 | 89.9 | 74.7 | 0.816 |
| LLM-only | 657 | 11 | 362 | 295 | 64.5 | 98.4 | 0.779 |
| Config. | Precision (%) | Recall (%) | FPR (%) | |
|---|---|---|---|---|
| D | ||||
| L | ||||
| D + L | ||||
| D + V | ||||
| L + V | ||||
| D + L + V |
| Config. | Precision (%) | Recall (%) | FPR (%) | |
|---|---|---|---|---|
| + IL | ||||
| + ME | ||||
| + IL + ME | ||||
| + IL + V | ||||
| + ME + V | ||||
| + IL + ME + V |
| Mitigation | Findings |
|---|---|
| Substitution alone | 13 |
| Substitution with configuration | 1 |
| Executable-code patch alone | 4 |
| Executable-code patch with configuration | 0 |
| Instruction patch alone | 17 |
| Instruction patch with configuration | 20 |
| Outcome | Findings |
|---|---|
| Effective in the tested conditions | 47 |
| Partially mitigated | 6 |
| Unresolved after testing | 0 |
| Effectiveness not evaluated | 2 |
| Total | 55 |
| Skill | Gate on Sending | Local Analysis Result |
|---|---|---|
| slackapi/slack-messaging * | host (MCP tool approval) | none reported |
| slackapi/slack-api * | instruction (confirm writes) | none reported |
| idanbeck/slack-skill | instruction (confirm each send) | undeclared network use |
| openclaw/slack-personal | optional draft review | none reported |
| devxoul/agent-slack | none | excessive agency |
| devxoul/agent-slackbot | none | excessive agency |
Agent Skill Security Auditing
Agent skill security auditing examines reusable agent instructions, code, and tools for malicious behavior, unsafe permissions, and supply-chain risks.
See all 69 papers