Fix BeyondTrust PRA/RS exploit failing on older instances#20938
Merged
bwatters-r7 merged 4 commits intorapid7:masterfrom Feb 20, 2026
Merged
Fix BeyondTrust PRA/RS exploit failing on older instances#20938bwatters-r7 merged 4 commits intorapid7:masterfrom
bwatters-r7 merged 4 commits intorapid7:masterfrom
Conversation
The /get_mech_list?version=3 endpoint returns HTTP 500 on older BeyondTrust versions that do not support the JSON API. Add a fallback to version=2 which returns semicolon-separated key=value pairs (e.g. "company=sewtest;product=ingredi"). Also remove the "Thank you for using BeyondTrust" check in the BRDF validation, as PRA instances do not contain this string, causing the check method to incorrectly report Unknown for PRA targets.
jvoisin
reviewed
Feb 10, 2026
Co-authored-by: Julien Voisin <jvoisin@users.noreply.github.com>
Co-authored-by: Julien Voisin <jvoisin@users.noreply.github.com>
Co-authored-by: Julien Voisin <jvoisin@users.noreply.github.com>
bwatters-r7
approved these changes
Feb 20, 2026
Contributor
|
I only have access to 24.1.2, but I can confirm no regressions. |
Contributor
Release NotesImproves the check method in the |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The
get_site_info_via_mech_listmethod only queries/get_mech_list?version=3which returns JSON on newer BeyondTrust instances. On older instances (e.g. 22.x), this endpoint returns HTTP 500, causing the company name lookup to fail and the exploit to abort with "Invalid company or app name".This PR adds a fallback to
/get_mech_list?version=2, which returns semicolon-separated key=value pairs (e.g.company=example;product=ingredi) and works on all tested versions.Also removes the
"Thank you for using BeyondTrust"string check in thecheckmethod's BRDF validation. Privileged Remote Access (PRA) instances do not contain this string in their BRDF data, causingcheckto incorrectly returnUnknownfor PRA targets.Verification
msfconsoleuse exploits/linux/http/beyondtrust_pra_rs_unauth_rceset RHOSTS <target>(an older BeyondTrust RS instance, e.g. version 22.x)set RPORT 443set SSL trueset VERBOSE truecheckcheckreturnsAppearswith detected version (previously failed withUnknownon 22.x instances because version=3 returned HTTP 500)Got site info via the /get_mech_list?version=2 endpoint.confirming the v2 fallback was usedcheckalso works on newer instances (version=3 JSON path still tried first)Tested on
checkreturnsAppearswith detected version (previously failed, v3 returns HTTP 500, v2 fallback succeeds)