Back to skill

Security audit

Outlook Plus

Security checks for vulnerabilities and agentic risk

Overview

The skill is a disclosed Outlook email/calendar integration, but its local credential handling and setup guidance create risks users should review before installing.

Install only if you are comfortable granting this skill read/write/send access to Outlook mail and read/write access to calendars. Avoid printing tokens except for controlled debugging, protect ~/.outlook-mcp, use simple account names, and prefer official package-manager Azure CLI installation instructions rather than the printed curl | sudo bash command.

Vulnerability Patterns
  • Remote Payload Retrieval and ExecutionFetches external code whose behavior can change after review
  • Insecure Skill Coding PracticesFinds exploitable flaws such as hardcoded secrets or command injection
  • Skill Instruction HijackingAlters the agent's session goals or safety constraints when the skill loads
  • Agent Memory PoisoningWrites attacker-controlled rules into memory that affect later sessions
  • Embedded Malicious CodeShips malicious scripts inside the skill and executes them locally
Findings (2)

T03 · Remote Payload Retrieval and Execution

Error
Location
scripts/outlook-setup.sh:37
Finding

Suggested execution of an unpinned remote installer with root privileges

Content
View full analysis
/dev/null; then echo -e "${RED}Error: Azure CLI not installed${NC}" echo "Install with: curl -sL https://aka.ms/InstallAzureCLIDeb | sudo bash" exit 1 fi ``` ### Technical Analysis When Azure CLI is unavailable, the setup script instructs the user to pipe a remotely retrieved shell script directly into `sudo bash`. The command is printed rather than automatically executed, but it is presented as the prescribed installation procedure during a trusted setup workflow. The effective payload is retrieved from a mutable URL at execution time. It is not pinned to a specific version, downloaded for inspection, or verified using a cryptographic checksum or package signature before receiving root privileges. The use of a Microsoft-controlled HTTPS domain reduces—but does not eliminate—the supply-chain risk. This behavior is not the minimum privilege necessary for the Skill. Azure CLI is a legitimate dependency, but installing it through an unverified network-to-root shell pipeline is not required for Outlook mail or calendar functionality. ### Attack Path 1. A user runs `scripts/outlook-setup.sh` on a system without Azure CLI. 2. The script displays `curl -sL https://aka.ms/InstallAzureCLIDeb | sudo bash` as the installation command. 3. The user executes that command while relying on the Skill's setup instructions. 4. `curl` follows the redirect and retrieves the current remote installer. 5. The installer is passed directly to a root shell without local inspection or integrity verification. 6. If the remote script, redirect destination, hosting infrastructure, or trusted delivery chain is compromised, attacker-controlled commands execute as root. ### Impact Assessment Successful exploitation provides arbitrary com ...[truncated 432 chars]
Remediation
View remediation

T09 · Insecure Skill Coding Practices

Error
Location
scripts/outlook-setup.sh:9
Finding

Unvalidated account names permit credential-path traversal and file overwrite

Content
View full analysis
"$CONFIG_FILE" << EOF { "client_id": "$CLIENT_ID", "client_secret": "$CLIENT_SECRET" } EOF chmod 600 "$CONFIG_FILE" echo -e "${GREEN}✓ Config saved to $CONFIG_FILE${NC}" } ``` OAuth credentials are also written to the attacker-influenced path: ```bash if echo "$TOKEN_RESPONSE" | jq -e '.access_token' > /dev/null 2>&1; then echo "$TOKEN_RESPONSE" > "$CREDS_FILE" chmod 600 "$CREDS_FILE" echo -e "${GREEN}✓ Tokens saved to $CREDS_FILE${NC}" fi ``` ### Technical Analysis `ACCOUNT` can originate from either the `--account` argument or the `OUTLOOK_ACCOUNT` environment variable. No allowlist, canonicalization, traversal check, or base-directory containment check is applied. An account value containing components such as `../../target` causes `CONFIG_DIR` to resolve outside `~/.outlook-mcp`. During setup, the script creates that directory and writes files named `config.json` and `credentials.json` into it. Shell quoting prevents command injection, but it does not prevent ...[truncated 2071 chars]
Remediation
View remediation
&2 exit 1 ;; esac } ``` 2. Apply identical validation in all four scripts, including values obtained from `OUTLOOK_ACCOUNT`. 3. Canonicalize `BASE_DIR` and `CONFIG_DIR`, then verify that the resolved account directory remains a direct child of `BASE_DIR`. 4. Reject absolute paths, slash characters, traversal components, control characters, and account names beginning with unexpected path syntax. 5. Set `umask 077` before creating credential directories or files. 6. Create the base and account directories with explicit restrictive permissions, such as mode `700`. 7. Refuse to write through symbolic links. Use safe creation methods that provide no-follow and exclusive-creation semantics where available. 8. Write credentials to a securely created temporary file inside the validated account directory, set mode `600`, and atomically rename it into place. 9. Reapply and verify restrictive permissions after token refreshes. 10. Consider replacing plaintext client-secret storage with the operating system's credential manager or keychain. ]]>
Vulnerability Patterns
  • Privilege EscalationExcessive Permissions, Sudo/Root Execution, Credential Access
  • MCP Tool PoisoningHidden Instructions, Unicode Deception, Parameter Description Injection
  • Prompt InjectionInstruction Override, Hidden Instructions, Exfiltration Commands
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
  • Supply ChainUnpinned Dependencies, External Script Fetching, Obfuscated Code
Findings (104)

Tp4

High
Category
MCP Tool Poisoning
Confidence
98% confidence
Finding

The documentation explicitly includes OAuth token refresh, credential storage, account migration, and a command that prints access tokens, yet the declared purpose focuses on email/calendar tasks. Hiding credential-management and token-exposure functions behind a productivity skill materially increases risk because these features can enable account takeover or unauthorized API use.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
98% confidence
Finding

The documentation explicitly includes OAuth token refresh, credential storage, account migration, and a command that prints access tokens, yet the declared purpose focuses on email/calendar tasks. Hiding credential-management and token-exposure functions behind a productivity skill materially increases risk because these features can enable account takeover or unauthorized API use.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
96% confidence
Finding

The documentation explicitly includes OAuth token refresh, credential storage, account migration, and a command that prints access tokens, yet the declared purpose focuses on email/calendar tasks. Hiding credential-management and token-exposure functions behind a productivity skill materially increases risk because these features can enable account takeover or unauthorized API use.

Content

No source excerpt is available for this finding.

Credential Access

High
Category
Privilege Escalation
Confidence
95% confidence
Finding

The metadata explicitly states that setup stores client ID, client secret, and OAuth tokens locally and that the token script can print access tokens. A capability to reveal live bearer tokens is dangerous because anyone who obtains the printed token can directly access Microsoft Graph with the user's privileges until expiry, and refresh-token handling increases persistence risk.

Content

Scanner excerpt · SKILL.md (reported line 7)May include surrounding context.

md
version: 1.9.0
author: cristiandan
homepage: https://github.com/cristiandan/outlook-skill
metadata: {"clawdbot":{"requires":{"bins":["az","jq"]},"credentials":{"note":"Setup creates Azure App Registration and stores client_id/client_secret/OAuth tokens in ~/.outlook-mcp. The token script can print access tokens. Treat these as sensitive."}}}
---

# Outlook Skill

Ae1

High
Category
analysis-evasion
Confidence
100% confidence
Finding

Referenced artifact was not completely inspected

Content

Scanner excerpt · SKILL.md (reported line 44)May include surrounding context.

md
./scripts/outlook-mail.sh --account work inbox

Ae1

High
Category
analysis-evasion
Confidence
100% confidence
Finding

Referenced artifact was not completely inspected

Content

Scanner excerpt · SKILL.md (reported line 52)May include surrounding context.

md
./scripts/outlook-mail.sh --account work inbox

Ae1

High
Category
analysis-evasion
Confidence
100% confidence
Finding

Referenced artifact was not completely inspected

Content

Scanner excerpt · SKILL.md (reported line 84)May include surrounding context.

md
./scripts/outlook-mail.sh --account work inbox

Ae1

High
Category
analysis-evasion
Confidence
100% confidence
Finding

Referenced artifact was not completely inspected

Content

Scanner excerpt · SKILL.md (reported line 85)May include surrounding context.

md
./scripts/outlook-mail.sh --account work inbox

Ae1

High
Category
analysis-evasion
Confidence
100% confidence
Finding

Referenced artifact was not completely inspected

Content

Scanner excerpt · SKILL.md (reported line 86)May include surrounding context.

md
./scripts/outlook-mail.sh --account work inbox

Ae1

High
Category
analysis-evasion
Confidence
100% confidence
Finding

Referenced artifact was not completely inspected

Content

Scanner excerpt · SKILL.md (reported line 87)May include surrounding context.

md
./scripts/outlook-mail.sh --account work inbox

Ae1

High
Category
analysis-evasion
Confidence
100% confidence
Finding

Referenced artifact was not completely inspected

Content

Scanner excerpt · SKILL.md (reported line 88)May include surrounding context.

md
./scripts/outlook-mail.sh --account work inbox

Ae1

High
Category
analysis-evasion
Confidence
100% confidence
Finding

Referenced artifact was not completely inspected

Content

Scanner excerpt · SKILL.md (reported line 89)May include surrounding context.

md
./scripts/outlook-mail.sh --account work inbox

Ae1

High
Category
analysis-evasion
Confidence
100% confidence
Finding

Referenced artifact was not completely inspected

Content

Scanner excerpt · SKILL.md (reported line 95)May include surrounding context.

md
./scripts/outlook-mail.sh --account work inbox

Ae1

High
Category
analysis-evasion
Confidence
100% confidence
Finding

Referenced artifact was not completely inspected

Content

Scanner excerpt · SKILL.md (reported line 98)May include surrounding context.

md
./scripts/outlook-mail.sh --account work inbox

Ae1

High
Category
analysis-evasion
Confidence
100% confidence
Finding

Referenced artifact was not completely inspected

Content

Scanner excerpt · SKILL.md (reported line 101)May include surrounding context.

md
./scripts/outlook-mail.sh --account work inbox

Ae1

High
Category
analysis-evasion
Confidence
100% confidence
Finding

Referenced artifact was not completely inspected

Content

Scanner excerpt · SKILL.md (reported line 104)May include surrounding context.

md
./scripts/outlook-mail.sh --account work inbox

Ae1

High
Category
analysis-evasion
Confidence
100% confidence
Finding

Referenced artifact was not completely inspected

Content

Scanner excerpt · SKILL.md (reported line 118)May include surrounding context.

md
./scripts/outlook-mail.sh --account work inbox

Ae1

High
Category
analysis-evasion
Confidence
100% confidence
Finding

Referenced artifact was not completely inspected

Content

Scanner excerpt · SKILL.md (reported line 119)May include surrounding context.

md
./scripts/outlook-mail.sh --account work inbox

Ae1

High
Category
analysis-evasion
Confidence
100% confidence
Finding

Referenced artifact was not completely inspected

Content

Scanner excerpt · SKILL.md (reported line 120)May include surrounding context.

md
./scripts/outlook-mail.sh --account work inbox

Ae1

High
Category
analysis-evasion
Confidence
100% confidence
Finding

Referenced artifact was not completely inspected

Content

Scanner excerpt · SKILL.md (reported line 121)May include surrounding context.

md
./scripts/outlook-mail.sh --account work inbox

Ae1

High
Category
analysis-evasion
Confidence
100% confidence
Finding

Referenced artifact was not completely inspected

Content

Scanner excerpt · SKILL.md (reported line 122)May include surrounding context.

md
./scripts/outlook-mail.sh --account work inbox

Ae1

High
Category
analysis-evasion
Confidence
100% confidence
Finding

Referenced artifact was not completely inspected

Content

Scanner excerpt · SKILL.md (reported line 123)May include surrounding context.

md
./scripts/outlook-mail.sh --account work inbox

Ae1

High
Category
analysis-evasion
Confidence
100% confidence
Finding

Referenced artifact was not completely inspected

Content

Scanner excerpt · SKILL.md (reported line 124)May include surrounding context.

md
./scripts/outlook-mail.sh --account work inbox

Ae1

High
Category
analysis-evasion
Confidence
100% confidence
Finding

Referenced artifact was not completely inspected

Content

Scanner excerpt · SKILL.md (reported line 129)May include surrounding context.

md
./scripts/outlook-mail.sh --account work inbox

Ae1

High
Category
analysis-evasion
Confidence
100% confidence
Finding

Referenced artifact was not completely inspected

Content

Scanner excerpt · SKILL.md (reported line 130)May include surrounding context.

md
./scripts/outlook-mail.sh --account work inbox

Static analysis

No suspicious patterns detected.