Cyber Resilience

CVE-2025-0218

Crypto Weakness in Pgadmin Pgagent ≤ 4.2.3

Published
07 January 2025
Modified
03 November 2025
Patch / advisory
CVSS Score v3.1 5.5
Click a component to see what it means
Raw vectorCVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H
EPSS Score 0.0017 7th percentile
Risk Priority 41 floored blend · peak EPSS

Summary

CVE-2025-0218 is a medium-severity Generation of Predictable Numbers or Identifiers (CWE-340) vulnerability in Pgadmin Pgagent. Its CVSS base score is 5.5 (Medium).

Operationally, exploitation aligns with the MITRE ATT&CK technique Forge Web Credentials (T1606); ranked at the 7th percentile by exploit likelihood (below the median); it is not currently listed in the CISA KEV catalog.

The strongest mitigations our analysis identified map to SA-11 (Developer Testing and Evaluation) and SC-12 (Cryptographic Key Establishment and Management) — see the control section below for these in your framework.

Deeper analysis AI-assisted summary

Synthesised by an AI model from the NVD description and linked references — a reading aid, not an authoritative source.

CVE-2025-0218 is a vulnerability in pgAgent, a job scheduling agent for PostgreSQL, affecting versions prior to 4.2.3. When batch jobs are executed, pgAgent creates a script in a temporary directory, but it uses an insufficiently seeded random number generator to generate the directory name. This predictable naming allows a local attacker to pre-create the directory, preventing pgAgent from writing the script and thus blocking job execution, which disrupts scheduled tasks. The issue is linked to CWE-340 (Generation of Predictable Numbers) and CWE-330 (Use of Insufficiently Random Values).

A local attacker with low privileges (PR:L) can exploit this vulnerability with low complexity and no user interaction required (AV:L/AC:L/UI:N). Successful exploitation results in a denial-of-service condition with high availability impact (A:H), as targeted batch jobs fail to run, but there is no impact on confidentiality or integrity (C:N/I:N). The CVSS v3.1 base score is 5.5, classifying it as medium severity, limited to the local scope (S:U).

Mitigation involves upgrading to pgAgent version 4.2.3 or later, where the random number generator seeding has been improved, as detailed in the fixing commit at https://github.com/pgadmin-org/pgagent/commit/1ecd193a2be3a3dc9e98f369495e1a792e6d508c. Debian LTS users should refer to the security advisory at https://lists.debian.org/debian-lts-announce/2025/10/msg00018.html for package updates and additional guidance.

OWASP Top 10 for Web (2025)

EU & UK References

Vulnerability Data

When batch jobs are executed by pgAgent, a script is created in a temporary directory and then executed. In versions of pgAgent prior to 4.2.3, an insufficiently seeded random number generator is used when generating the directory name, leading to…

more

the possibility for a local attacker to pre-create the directory and thus prevent pgAgent from executing jobs, disrupting scheduled tasks.

CWE(s)

Related Threats

MITRE ATT&CK Enterprise Techniques

T1606 Forge Web Credentials Credential Access
Adversaries may forge credential materials that can be used to gain access to web applications or Internet services.
T1606.001 Web Cookies Credential Access
Adversaries may forge web cookies that can be used to gain access to web applications or Internet services.
T1110 Brute Force Credential Access
Adversaries may use brute force techniques to gain access to accounts when passwords are unknown or when password hashes are obtained.
T1185 Browser Session Hijacking Collection
Adversaries may take advantage of security vulnerabilities and inherent functionality in browser software to change content, modify user-behaviors, and intercept information as part of various browser session hijacking techniques.
T1558 Steal or Forge Kerberos Tickets Credential Access
Adversaries may attempt to subvert Kerberos authentication by stealing or forging Kerberos tickets to enable [Pass the Ticket](https://attack.
T1563 Remote Service Session Hijacking Lateral Movement
Adversaries may take control of preexisting sessions with remote services to move laterally in an environment.
Derived from this CVE’s CWE(s) via the direct CWE→ATT&CK cross-walk.

CVEs Like This One

CVE-2026-45673Shared CWE-330, CWE-340
CVE-2026-40496Shared CWE-330, CWE-340
CVE-2026-7820Same vendor: Pgadmin
CVE-2026-7814Same vendor: Pgadmin
CVE-2025-2946Same vendor: Pgadmin
CVE-2026-12048Same vendor: Pgadmin
CVE-2026-12047Same vendor: Pgadmin
CVE-2024-9014Same vendor: Pgadmin
CVE-2026-17349Same vendor: Pgadmin
CVE-2026-7813Same vendor: Pgadmin

Affected Assets

pgadmin
pgagent
≤ 4.2.3

Mitigating Controls

Control response

Prevent
Stop it (NIST 800-53)

Detect
Catch it (NIST detect / respond)

Harden
Shrink the surface (DISA STIG)
  • 14 hardening rules · 5 OS baselines
Validate
Prove the fix (OWASP ASVS)
  • V11.3.4

Mitigating Controls (NIST 800-53 r5) AI

Developer testing and evaluation can discover predictable number generation through targeted analysis or fuzzing of identifier creation routines.

Cryptographic key establishment and management mandates proper entropy and randomness during generation, directly stopping predictable identifiers at the source.

Authenticator management requires secure initial distribution and handling of authenticators, structurally preventing predictable values from being usable.

SC-13 requires selection and implementation of approved cryptographic algorithms and methods, which inherently depend on and enforce sufficiently random values.

Mitigating Controls (NIST CSF 2.0) AI

Derived directly from the weakness types (CWEs) cited in the NVD entry via our AI-authored CWE→CSF cross-walk (authority under review) — links open the control.

PR.PS-06 mostly match
prevents

Secure SDLC practices directly require cryptographically strong RNG for identifiers and tokens, covering most of this weakness while the control addresses many additional development issues.

Mitigating Controls (ISO/IEC 27001:2022 Annex A) AI

Derived directly from the weakness types (CWEs) cited in the NVD entry via our AI-authored CWE→ISO cross-walk (authority under review) — links open the control.

prevents

Cryptographic controls require use of approved, sufficiently random algorithms and key-generation methods, directly mitigating predictable number/identifier weaknesses.

finds

Security testing in development can detect predictable identifiers through static/dynamic analysis and fuzzing, reducing residual risk.

prevents

A secure SDLC incorporates threat modelling and secure-design reviews that flag predictable identifier generation early in the lifecycle.

prevents

Secure-coding standards explicitly forbid predictable random functions and mandate cryptographically secure RNGs, preventing the weakness at the source.

prevents

Secure authentication mechanisms depend on unpredictable session tokens, nonces and challenges; eliminating predictable identifiers strengthens authentication integrity.

Hardening callouts derived

Configuration rules from DISA STIG baselines that bear on weaknesses of the type cited by this CVE. Each rule is shown with the relationship its mapping actually records, against the CWE it was authored against. Derived via CVE→CWE over `controls_xwalks` (authoritative rows only; rows rated `none` are excluded).

Oracle Linux 8 (4 rules)
  • V-248524 OL 8 must implement NIST FIPS-validated cryptography for the following: To provision digital signatures, to generate cryptographic hashes, and to protect data requiring data-at-rest protections in accordance with applicable federal laws, Executive Orders, directives, policies, regulations, and standards. prevents CWE-340
  • V-248563 The OL 8 SSH server must be configured to use strong entropy. prevents CWE-330
  • V-248599 OL 8 must enable the hardware random number generator entropy gatherer service. prevents CWE-330
Oracle Linux 9 (1 rule)
  • V-271511 OL 9 must enable the hardware random number generator entropy gatherer service. prevents CWE-330
RHEL 7 (1 rule)
  • V-204497 The Red Hat Enterprise Linux operating system must implement NIST FIPS-validated cryptography for the following: to provision digital signatures, to generate cryptographic hashes, and to protect data requiring data-at-rest protections in accordance with applicable federal laws, Executive Orders, directives, policies, regulations, and standards. prevents CWE-340
RHEL 8 (3 rules)
  • V-244527 RHEL 8 must have the packages required to use the hardware random number generator entropy gatherer service. prevents CWE-330, CWE-340
  • V-230253 RHEL 8 must ensure the SSH server uses strong entropy. prevents CWE-330
  • V-230285 RHEL 8 must enable the hardware random number generator entropy gatherer service. prevents CWE-330
RHEL 9 (1 rule)
  • V-257782 RHEL 9 must enable the hardware random number generator entropy gatherer service. prevents CWE-330

References