vendor:
PostgreSQL
by:
Paulo Trindade, Bruno Stabelini, Diego Farias and Weslley Shaimon
7.2
CVSS
HIGH
Remote Code Execution (RCE)
78
CWE
Product Name: PostgreSQL
Affected Version From: PostgreSQL 9.6.1
Affected Version To: PostgreSQL 9.6.1
Patch Exists: YES
Related CWE: CVE-2019-9193
CPE: a:postgresql:postgresql:9.6.1
Other Scripts:
https://www.infosecmatter.com/metasploit-module-library/?mm=exploit/multi/postgres/postgres_copy_from_program_cmd_exec, https://www.infosecmatter.com/nessus-plugin-library/?id=126899, https://www.infosecmatter.com/list-of-metasploit-linux-exploits-detailed-spreadsheet/, https://www.infosecmatter.com/list-of-metasploit-windows-exploits-detailed-spreadsheet/
Platforms Tested: Red Hat Enterprise Linux Server 7.9
2023
PostgreSQL 9.6.1 – Remote Code Execution (RCE) (Authenticated)
This exploit allows an authenticated user to execute arbitrary system commands on a vulnerable PostgreSQL 9.6.1 instance. The exploit uses a PostgreSQL feature called PL/pgSQL to execute the commands. The exploit requires the user to provide the IP address, port, username and password of the PostgreSQL instance. The user can then provide a system command to be executed on the vulnerable instance.
Mitigation:
The user should ensure that the PostgreSQL instance is running the latest version of the software and that all security patches are applied.