Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remote command Execution by an Authenticated user in pgAdmin 4 #6763

Closed
adityatoshniwal opened this issue Sep 18, 2023 · 1 comment
Closed

Comments

@adityatoshniwal
Copy link
Contributor

Vulnerable versions: All prior to v7.6.

The pgAdmin server includes an HTTP API that is intended to be used to validate the path a user selects to external PostgreSQL utilities such as pg_dump and pg_restore. The utility is executed by the server to determine what PostgreSQL version it is from.

Versions of pgAdmin prior to 7.6 failed to properly control the server code executed on this API, which could allow an authenticated user to run arbitrary commands on the server. Users can use the commands as filenames and check for validating the path using the API. This would inject the command in the path validator and execute the command on the pgAdmin server.

This issue does not affect users running pgAdmin in desktop mode.

The pgAdmin project thanks Stefan Grönke <gronke@radicallyopensecurity.com> for reporting this issue.

@adityatoshniwal adityatoshniwal added this to the 7.7 milestone Sep 18, 2023
adityatoshniwal added a commit to adityatoshniwal/pgadmin4 that referenced this issue Sep 18, 2023
…te command using validate binary path API. pgadmin-org#6763

CVE-XXXX-XXXXX - request raised, number to be received.
adityatoshniwal added a commit to adityatoshniwal/pgadmin4 that referenced this issue Sep 18, 2023
adityatoshniwal added a commit that referenced this issue Sep 18, 2023
adityatoshniwal added a commit to adityatoshniwal/pgadmin4 that referenced this issue Sep 20, 2023
adityatoshniwal added a commit that referenced this issue Sep 20, 2023
@adityatoshniwal
Copy link
Contributor Author

Tested on Ubuntu 22 with https://developer.pgadmin.org/builds/2023-09-20-2/ builds. Works fine.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant