# Duplicate Advisory: phpseclib: guardrails needed on isPrime and randomPrime

Advisory record · `GHSA-hg35-mp25-qf6h` · Withdrawn

- **Identifiers:** `GHSA-hg35-mp25-qf6h`
- **State:** Withdrawn
- **Severity:** CVSS 7.5 High
- **Critical:** No
- **Weakness (CWE):** [CWE-400](https://cwe.mitre.org/data/definitions/400.html)
- **Tags:** [Denial of service](https://agentprime.io/advisories/tag/dos.md)
- **Published:** 2 Mar 2024
- **Updated:** 10 Sept 2026
- **Reviewed by a person:** No

**Withdrawn.** The GitHub Advisory Database withdrew this advisory on 6 May 2026. The record stays here, marked withdrawn.

Published by the GitHub Advisory Database at 2 Mar 2024, 00:31 UTC. agentprime has not analysed this yet, so whether it affects any app is not known.

## Affected packages

- `phpseclib/phpseclib` (Packagist): affected `>=1.0.0, <1.0.23 || >=2.0.0, <2.0.47 || >=3.0.0, <3.0.36`; fixed in `1.0.23`, `2.0.47`, `3.0.36`

## Not analysed yet

We haven’t published our analysis of this Advisory yet. Once a person has reviewed it, this page will say what’s vulnerable, what has to be true for your app to be affected, and how to check.

## Severity and exploitation

- 7.5 High, CVSS 3.1: `CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H`, from GitHub Advisory Database

- **CISA KEV:** Not listed.
- **EPSS:** No score.

## Timeline

This record came from the full history of the GitHub Advisory Database, published 2 Mar 2024. New records show when each source confirmed them.

## Sources

- [GitHub Advisory Database: GHSA-hg35-mp25-qf6h](https://github.com/advisories/GHSA-hg35-mp25-qf6h)
- [OSV: GHSA-hg35-mp25-qf6h](https://osv.dev/vulnerability/GHSA-hg35-mp25-qf6h)
- <https://nvd.nist.gov/vuln/detail/CVE-2024-27354>
- <https://github.com/phpseclib/phpseclib/commit/2870c8fab3f132d2ed40a66c97a36fe5ab625698>
- <https://github.com/phpseclib/phpseclib/commit/ad5dbdf2129f5e0fb644637770b7f33de8ca8575>
- <https://github.com/phpseclib/phpseclib/commit/c55b75199ec8d12cec6eadf6da99da4a3712fe56>
- <https://gist.github.com/katzj/ee72f3c2a00590812b2ea3c0c8890e0b>
- <https://github.com/FriendsOfPHP/security-advisories/blob/master/phpseclib/phpseclib/CVE-2024-27354.yaml>
- <https://github.com/advisories/GHSA-hg35-mp25-qf6h>
- <https://github.com/phpseclib/phpseclib>
- <https://github.com/phpseclib/phpseclib/blob/master/phpseclib/Math/PrimeField.php#L49>
- <https://lists.debian.org/debian-lts-announce/2024/03/msg00002.html>
- <https://lists.debian.org/debian-lts-announce/2024/03/msg00003.html>

Facts on this page come from the GitHub Advisory Database (CC-BY 4.0), OSV and the other sources listed, as published. We don’t reproduce full advisory descriptions, which can contain exploit code.

## Check whether this affects you

A Match means an installed version is in the affected range above. Most don’t affect the app; agentprime hasn’t analysed this one yet.

- With the agentprime MCP server (<https://api.agentprime.io/mcp>), ask your agent to check the project: `check_lockfile` sends a lockfile, `check_packages` a list of installed packages, and both return the Matches and the upgrades that clear them. `get_advisory` returns this record. Setup: <https://agentprime.io/mcp.md>
- In a browser: <https://agentprime.io/check/> reads your lockfile in the browser, never uploading it.
- Whether it touches your code, with file and line: the Claude Code plugin, <https://agentprime.io/plugin.md>
- As JSON: <https://api.agentprime.io/v1/advisories/GHSA-hg35-mp25-qf6h>, or `POST https://api.agentprime.io/v1/match` with your packages (<https://agentprime.io/api.md>)

---

The web page: <https://agentprime.io/advisories/GHSA-hg35-mp25-qf6h/>. Everything for agents: <https://agentprime.io/llms.txt>.
