-
Notifications
You must be signed in to change notification settings - Fork 14.2k
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
Exploit module for BeyondTrust Privileged Remote Access & Remote Support (CVE-2024-12356, CVE-2025-1094) #19877
base: master
Are you sure you want to change the base?
Conversation
…led by default, and we hit the SQLi directly.
…ndocumented API endpoint to discover the target site company name.
Adding a comment here to mention that this module relies on #19834 - to fix an issue with WebSockets, so dropping the module into an older version of the framework wont work, you need to run MSF that has the WebSocket bug fix in it (MSF 6.4.47 and above). |
'DisableNops' => true, | ||
# Our payload is passed to the PHP function pg_escape_string. We want to avoid any single quotes | ||
# getting escaped unexpectedly. The server may be configured to escape double quotes (not by default). | ||
# We also want to avoid any forward slash characters if CVE-2024-12356 is being leveraged. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
# We also want to avoid any forward slash characters if CVE-2024-12356 is being leveraged. | |
# We also want to avoid any backward slash characters if CVE-2024-12356 is being leveraged. |
|
||
return CheckCode::Unknown('Connection failed') unless res | ||
|
||
return CheckCode::Unknown("Unexpected response code #{res.code == 200}") unless res.code == 200 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
return CheckCode::Unknown("Unexpected response code #{res.code == 200}") unless res.code == 200 | |
return CheckCode::Unknown("Unexpected response code #{res.code != 200}") unless res.code == 200 |
# 00000020 44 46 80 00 0a 91 07 81 32 34 2e 31 2e 32 00 82 |DF......24.1.2..| | ||
# 00000030 00 00 00 00 67 8e 25 28 91 06 83 65 6e 2d 75 73 |....g.%(...en-us| | ||
|
||
# First there is a "0 Successful\nLOCALE_ID\nTIMESTAMP\n" value, we we use a regex to match this so we can ignore it. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
# First there is a "0 Successful\nLOCALE_ID\nTIMESTAMP\n" value, we we use a regex to match this so we can ignore it. | |
# First there is a "0 Successful\nLOCALE_ID\nTIMESTAMP\n" value, we use a regex to match this so we can ignore it. |
Overview
This pull request adds an unauthenticated RCE exploit module targeting BeyondTrust Privileged Remote Access & Remote Support, leveraging CVE-2024-12356 + CVE-2025-1094.
CVE-2024-12356 is an argument injection issue in the BeyondTrust code base, and CVE-2025-1094 is a SQL injection issue in the PostgreSQL code base (shipped as a component in the BeyondTrust appliance).
The exploit can either leverage CVE-2024-12356 and CVE-2025-1094 together, or solely leverage CVE-2025-1094 (this is the default) for RCE. Arbitrary code execution is achieved with the privileges of the current site user (i.e. not root).
For a full technical analysis of the vulnerabilities, please read our AttackerKB Rapid7 Analysis.
Example