# CVE-2026-77005: Code Monkeys Proposals <= 1.0.1 - Subscriber+ Arbitrary File Deletion via Path Traversal

The Markdown version of <https://upatch.dev/cve/CVE-2026-77005>. Last updated 25 Nov 2026.

## At a glance

CVE-2026-77005 is rated Critical 9.6 (CVSS 3.1, CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:C/C:N/I:H/A:H). It affects Code Monkeys Proposals and was published on 12 Sept 2026. It is not in CISA's Known Exploited Vulnerabilities catalog. Its EPSS score is 0.4%: the estimated chance it is exploited in the next 30 days, as of 25 Nov 2026. The upatch `cve-2026-77005-unlink-block` mitigates it, and is vetted (merged into the registry).

A upatch is a signed BPF program that shirudo loads into a running Linux kernel to block the code path this CVE's exploit takes. It holds the line until the fix ships; it does not replace patching.

## The vulnerability

CVE-2026-77005, "Code Monkeys Proposals <= 1.0.1 - Subscriber+ Arbitrary File Deletion via Path Traversal", was published on 12 September 2026. In `ajax-functions.php`, the `code_monkeys_proposals_delete_pdf` handler is registered on both `wp_ajax_code_monkeys_proposals_delete_pdf` and `wp_ajax_nopriv_code_monkeys_proposals_delete_pdf`, checks only the `cm-proposals-nonce` nonce (which `enqueue.php` localizes into `cmProposalsAdminScript` on every admin page, including for Subscribers), performs no capability check, and passes `plugin_dir_path(__FILE__) . 'proposals/' . sanitize_text_field($_REQUEST['file'])` directly to `unlink()`. Because `sanitize_text_field()` leaves `../` sequences intact, an attacker can traverse out of `wp-content/plugins/code-monkeys-proposals/proposals/` to unlink `wp-config.php` (forcing WordPress back into its installation wizard for site takeover) or plugin files.

### Official description

The CODE MONKEYS PROPOSALS WordPress plugin through 1.0.1 does not validate a user-supplied file path before deleting a file, and does not check the capability of the user making the request, allowing any authenticated user, such as a subscriber, to delete arbitrary files on the server, which can lead to a site takeover.

## What the upatch does

The program attaches to `lsm/inode_unlink` and returns `-EPERM` when a PHP or web-server process (`php*`, `apache2*`, `httpd*`, or `litespeed*`) attempts to unlink:

- `wp-config.php` or `.htaccess`, the primary site-takeover and configuration targets reached by traversing out of the plugin directory, or
- any file directly inside `code-monkeys-proposals/` or `code-monkeys-proposals/proposals/` whose name does not end in `.pdf` (the plugin's `code_monkeys_proposals_generate_pdf` function only ever writes `<templateName>-<time>.pdf` into `proposals/`).

A refusal from an earlier BPF LSM program on the same hook is passed on unchanged, and the `refused` per-CPU array map counts refused unlink attempts.

The policy: [`cve-2026-77005-unlink-block.bpf.c`](https://github.com/copper-helm/upatch-registry/tree/main/upatches/cve-2026-77005), 138 lines of BPF C attached at `lsm/inode_unlink`, licensed GPL-2.0 OR BSD-2-Clause.

## Side effects

- PHP processes cannot unlink `wp-config.php` or `.htaccess`, or unlink non-`.pdf` files inside `code-monkeys-proposals/` and `code-monkeys-proposals/proposals/`.
- Generating and deleting `.pdf` proposal files in `code-monkeys-proposals/proposals/` continues to work normally.
- Unlinking files in `code-monkeys-proposals/` from WordPress's web-based plugin deletion UI fails while the upatch is loaded; administrators can remove the plugin from a shell (such as via `rm` or `wp-cli` if run outside the PHP binary, or after unloading the upatch).

## Preemption model and cost

The program keeps no shared state beyond a single per-CPU counter updated with `__sync_fetch_and_add`, making it safe under every preemption model, including preemptible RCU (`PREEMPT_LAZY` and `PREEMPT_DYNAMIC`) and `PREEMPT_RT`. On each `inode_unlink` call, the program checks the target dentry's length and name first before inspecting parent dentries or the current task's executable.

## Affected versions

The vulnerability is in the Code Monkeys Proposals WordPress plugin through version 1.0.1 (closed on WordPress.org on 28 August 2026 with no patched release). The upatch uses the standard two-argument `inode_unlink` LSM hook (`struct inode *dir, struct dentry *dentry`) supported across mainline Linux kernels with BPF LSM enabled.

## How it was tested

On WordPress 6.7.2 with Code Monkeys Proposals 1.0.1, the loaded upatch refused the subscriber path-traversal file deletion outside proposals/ while allowing normal PDF deletion inside proposals/.

- **Tested:** 25 Nov 2026
- **Target:** Code Monkeys Proposals 1.0.1 on WordPress 6.7.2 (SQLite 2.1.16, PHP CLI built-in web server), loopback only
- **Kernel:** 7.4-shirudo-ci-20261123
- **Architecture:** x86_64

### Results

| State           | Path traversal unlink (../upatch-probe-\<token>.txt) | Normal PDF deletion in proposals/ |
| --------------- | ---------------------------------------------------- | --------------------------------- |
| Before loading  | deleted (reached)                                    | deleted                           |
| Upatch loaded   | refused with EPERM (blocked)                         | deleted                           |
| After unloading | deleted (reached)                                    | deleted                           |

## How to apply

Build the upatch from source, sign it with your own shirudo key, and publish it to your own OCI registry. Machines that follow your upatch tree load it within about a minute.

Build and sign:

```sh
git clone https://github.com/copper-helm/upatch-registry
cd upatch-registry
tools/build <shirudo-checkout> <keys-dir> 1.0.0 upatches/cve-2026-77005
```

Publish and roll out:

```sh
shirudo bpm push build/packages/cve-2026-77005-1.0.0.bee oci://<registry>/<namespace>/cve-2026-77005 --keys-dir <keys-dir>
shirudo bpm tree append build/packages/cve-2026-77005-1.0.0.bee oci://<registry>/<namespace>/<tree> --tree-id <tree-id> --keys-dir <keys-dir>
```

## Review

- Contributors: romanlab.
- Reviewers: none recorded yet.

## Sources and links

- [CVE-2026-77005 record (CVE API)](https://cveawg.mitre.org/api/cve/CVE-2026-77005)
- [WPScan advisory b9340774-84c2-41ec-a770-0123dd5608c2](https://wpscan.com/vulnerability/b9340774-84c2-41ec-a770-0123dd5608c2/)
- [WordPress plugin page](https://wordpress.org/plugins/code-monkeys-proposals/)
- [Plugin source code (1.0.1 tag in WordPress SVN)](https://plugins.svn.wordpress.org/code-monkeys-proposals/tags/1.0.1/ajax-functions.php)

### Links

- [CVE-2026-77005 on upatch.dev](https://upatch.dev/cve/CVE-2026-77005) (this page, as HTML)
- [NVD](https://nvd.nist.gov/vuln/detail/CVE-2026-77005)
- [CVE.org](https://www.cve.org/CVERecord?id=CVE-2026-77005)
- [CWE-73](https://cwe.mitre.org/data/definitions/73.html)
- Upatch source: [upatches/cve-2026-77005](https://github.com/copper-helm/upatch-registry/tree/main/upatches/cve-2026-77005)

### More references from NVD (1)

- [wpscan.com](https://wpscan.com/vulnerability/b9340774-84c2-41ec-a770-0123dd5608c2/)
