Back to skill

Security audit

Overleaf

Security checks for vulnerabilities and agentic risk

Overview

This Overleaf skill is coherent, but it asks an agent to use browser session cookies and persistent keychain access while also enabling remote writes, deletes, downloads, and invite acceptance.

Review before installing. Use only with Overleaf accounts and projects where agent access is acceptable, prefer a dedicated browser profile limited to Overleaf, pin pyoverleaf to the audited version or verify the installed package yourself, and require explicit confirmation before any write, delete, download, or invite-acceptance action.

Vulnerability Patterns
  • Insecure DependenciesIntroduces malicious components through unsafe dependency sources
  • 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
  • Remote Payload Retrieval and ExecutionFetches external code whose behavior can change after review
  • Embedded Malicious CodeShips malicious scripts inside the skill and executes them locally
Findings (1)

T08 · Insecure Dependencies

Warning
Location
SKILL.md:12
Finding
Unpinned Third-Party Dependency Is Granted Broad Browser Cookie Access## Vulnerability Details **File Location**: `SKILL.md:12-22` **Vulnerability Type**: Unpinned security-sensitive third-party dependency **Risk Level**: Medium **Complete Code Snippet**: ```markdown ## Requirements - Python 3.8+ - pyoverleaf (`pipx install pyoverleaf`) - User logged into Overleaf in Chrome/Firefox ## Security Considerations ⚠️ **Keychain Access Required**: pyoverleaf needs "Always Allow" keychain access to read browser cookies. This grants the tool access to your browser's cookie storage. **Security audit**: We have audited pyoverleaf v0.1.7 and found it safe. The codebase is small and readable. Before installing, agents can self-audit the latest version at the GitHub repo above. ``` ### Technical Analysis The installation command `pipx install pyoverleaf` does not pin the dependency to the stated audited version, `v0.1.7`. Consequently, users may install a newer release whose source code differs from the reviewed version. This dependency is security-sensitive because the instructions ask users to grant it persistent “Always Allow” keychain access so that it can read browser cookie storage. Browser cookie access can expose authentication material beyond the narrow Overleaf operation being performed, depending on the browser-cookie library, operating system, browser profile, and keychain permission boundaries. The combination of an unpinned package and broad credential access creates a supply-chain risk. A malicious or compromised future package release could execute under the user's account and attempt to collect or misuse accessible browser session material. The audit found no evidence that the currently documented dependency is malicious; the vulnerability is the failure to ensure that the installed package is the reviewed package. The same unpinned installation command also appears in `README.md:16-18`: ```markdown # Install pyoverleaf CLI pipx install pyoverleaf ``` ### Attack Path ...[truncated 1934 chars]
Remediation
## Remediation Suggestions 1. Pin the dependency to the exact reviewed version: ```bash pipx install 'pyoverleaf==0.1.7' ``` 2. Distribute and verify a cryptographic hash or use a locked, reproducible dependency manifest so that installation resolves to the reviewed artifact. 3. Re-audit the dependency before updating the pinned version, and update the documented audited version and hashes together. 4. Prefer an Overleaf-scoped API token or another narrowly scoped authentication mechanism if supported. 5. If browser cookies remain necessary, instruct users to use a dedicated browser profile containing only the Overleaf session. 6. Avoid requesting persistent “Always Allow” keychain access when per-use authorization is sufficient. 7. Clearly document which cookie databases, domains, and keychain records the dependency can access. 8. Add dependency integrity and provenance checks to installation instructions, such as installing from a verified release artifact. 9. Remove the suggestion that users independently audit the unspecified “latest version”; package security should be enforced through a maintained pinning and review process rather than delegated to each user.
Vulnerability Patterns
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
  • Privilege EscalationExcessive Permissions, Sudo/Root Execution, Credential Access
  • Tool MisuseTool Parameter Abuse, Chaining Abuse, Unsafe Defaults
  • Trigger AbuseOverly Broad Trigger, Shadow Command Trigger, Keyword Baiting Trigger
  • Prompt InjectionInstruction Override, Hidden Instructions, Exfiltration Commands
Findings (11)

Credential Access

High
Category
Privilege Escalation
Content
- Python 3.8+
- Logged into Overleaf in Chrome/Firefox
- macOS: Grant keychain access on first run

## Example
Confidence
70% confidence
Finding
Code accesses credential files (SSH keys, AWS credentials, etc.). This could indicate credential theft attempts.

Credential Access

High
Category
Privilege Escalation
Content
## Security Considerations

⚠️ **Keychain Access Required**: pyoverleaf needs "Always Allow" keychain access to read browser cookies. This grants the tool access to your browser's cookie storage.

**Security audit**: We have audited pyoverleaf v0.1.7 and found it safe. The codebase is small and readable. Before installing, agents can self-audit the latest version at the GitHub repo above.
Confidence
95% confidence
Finding
The skill requests persistent keychain permission to access browser cookies, which exposes authenticated session data to the tool. Because cookie stores may cover more than a single Overleaf action, compromise or misuse of this capability could enable unauthorized access to user resources.

Credential Access

High
Category
Privilege Escalation
Content
## Security Considerations

⚠️ **Keychain Access Required**: pyoverleaf needs "Always Allow" keychain access to read browser cookies. This grants the tool access to your browser's cookie storage.

**Security audit**: We have audited pyoverleaf v0.1.7 and found it safe. The codebase is small and readable. Before installing, agents can self-audit the latest version at the GitHub repo above.
Confidence
95% confidence
Finding
The skill requests persistent keychain permission to access browser cookies, which exposes authenticated session data to the tool. Because cookie stores may cover more than a single Overleaf action, compromise or misuse of this capability could enable unauthorized access to user resources.

Credential Access

High
Category
Privilege Escalation
Content
pyoverleaf authenticates by reading cookies from your browser. The user must:

1. **Log into Overleaf** in Chrome or Firefox (visit overleaf.com and sign in)
2. **Grant keychain access** on first run (macOS will prompt for "Always Allow")

```bash
# Test auth - user should run this in their terminal first
Confidence
97% confidence
Finding
The authentication setup directs the user to log into Overleaf in a browser and then grant keychain access so the tool can authenticate by reading browser cookies. This is a true credential-access issue because it relies on harvesting existing browser session material rather than using isolated credentials for the specific tool.

Credential Access

High
Category
Privilege Escalation
Content
If you get auth errors:
- Ask user: "Are you logged into Overleaf in your browser?"
- If on macOS: "Did you approve the keychain access prompt with 'Always Allow'?"
- User may need to run `pyoverleaf ls` manually in terminal to trigger the keychain prompt

**Note**: The agent cannot log in for the user. Browser authentication must be done by the user directly.
Confidence
94% confidence
Finding
The troubleshooting guidance reinforces the keychain-approval flow and helps the user complete persistent cookie access, further operationalizing credential harvesting. In context, this is more dangerous because the same skill can read, write, download, and accept invites once browser-backed authentication succeeds.

Tool Parameter Abuse

High
Category
Tool Misuse
Content
pyoverleaf mkdir "Project Name/figures"

# Remove file/folder
pyoverleaf rm "Project Name/old-draft.tex"

# Download project as zip
pyoverleaf download-project "Project Name" output.zip
Confidence
89% confidence
Finding
The skill exposes a destructive removal command against remote project files and folders without any visible safeguards, validation, or confirmation requirements. In a broadly triggered skill that can operate on user projects via browser-backed auth, an agent could delete data due to prompt injection, ambiguous instructions, or user misunderstanding.

Credential Access

High
Category
Privilege Escalation
Content
```bash
  cat main.tex | PYOVERLEAF_HOST=www.overleaf.com pyoverleaf write "Project/main.tex"
  ```
- **Keychain Access Denied** (macOS): pyoverleaf needs keychain access to read browser cookies. User must run `pyoverleaf ls` in their terminal and click "Always Allow" on the keychain prompt
- **Project not found**: Use exact project name (case-sensitive), check with `pyoverleaf ls`
- **Permission denied**: User may not have edit access to the project
Confidence
93% confidence
Finding
This line documents a workflow where the user is told to approve keychain access for cookie retrieval, which remains a credential-access vulnerability regardless of its placement in troubleshooting. Because this skill operates on remote documents and invitations, successful cookie access can immediately translate into sensitive account actions.

Credential Access

High
Category
Privilege Escalation
Content
```bash
  cat main.tex | PYOVERLEAF_HOST=www.overleaf.com pyoverleaf write "Project/main.tex"
  ```
- **Keychain Access Denied** (macOS): pyoverleaf needs keychain access to read browser cookies. User must run `pyoverleaf ls` in their terminal and click "Always Allow" on the keychain prompt
- **Project not found**: Use exact project name (case-sensitive), check with `pyoverleaf ls`
- **Permission denied**: User may not have edit access to the project
Confidence
93% confidence
Finding
This line documents a workflow where the user is told to approve keychain access for cookie retrieval, which remains a credential-access vulnerability regardless of its placement in troubleshooting. Because this skill operates on remote documents and invitations, successful cookie access can immediately translate into sensitive account actions.

Missing User Warnings

Medium
Confidence
91% confidence
Finding
The README advertises write, sync, and download capabilities that can modify remote Overleaf content or overwrite local/remote files, but it does not warn users about destructive side effects or the need to confirm targets before syncing. In an agent skill context, this omission increases the chance of unintended data loss or project corruption because users may invoke the skill assuming read-only behavior.

Missing User Warnings

Medium
Confidence
92% confidence
Finding
The README states that authentication is performed via browser cookies without warning that these are sensitive session credentials equivalent to account access. In an AI-agent or CLI integration, encouraging browser-cookie reuse without privacy guidance can expose users to credential leakage, unintended account access, or unsafe handling of session material.

Vague Triggers

Medium
Confidence
92% confidence
Finding
The skill description uses very broad trigger phrases around Overleaf, LaTeX sync, uploads, and invite acceptance, which can cause the skill to activate in ordinary conversation without a clearly scoped user request. Overbroad activation is dangerous because this skill can read browser-authenticated project data and perform writes or invite acceptance, so accidental invocation increases the chance of unintended privileged actions.

Static analysis

No suspicious patterns detected.