Auth Bypass Round Two
An SSRF vulnerability in the SAML component of Ivanti Connect Secure allowed an attacker to make the server fetch an arbitrary URL. By pointing the SSRF at an internal REST API, the attacker could exploit a command injection flaw to execute code as root.
Published on assetnote.io
The Ivanti excitement continues! After an authentication bypass and command injection to kick off the year, Ivanti are following with a second authentication bypass and a privilege escalation.
The full write-up lives on its author's site
It belongs to its author, so we link to it rather than copy it. The other two tabs are our own rewrites, checked against it.
Not written yet. The AI write-up for this write-up has not been written yet. The Original tab links to the source.
How it worked
Root cause
Likely the SAML signature validation library (xmltooling) processes a KeyInfo element with a RetrievalMethod URI without restricting which URLs can be fetched, leading to SSRF.
Impact
An attacker could exploit this SSRF to bypass authentication and execute arbitrary commands as root on the device, potentially leading to full compromise.
What the attacker needed
Network access to the SAML endpoint; No authentication required
The fix
Ivanti released a patch that should address all the vulnerabilities; users are recommended to factory reset their devices and apply the patch.
How it was found
- Configure the Ivanti Connect Secure VM to use SAML authentication and capture a SAML response.
- Modify the SAML response by replacing the X509Data element in KeyInfo with a RetrievalMethod element pointing to a Burp Collaborator URL.
- Send the modified SAML response to the SAML consumer endpoint and observe the SSRF hit in Collaborator.
- Change the RetrievalMethod URI to target the internal REST API at http://[redacted]:8090 and include a command injection payload.
- Send the crafted SAML response to /dana-na/auth/saml-consumer.cgi or /dana-na/auth/saml-logout.cgi to trigger the SSRF and execute the command.
Explained by bugbounty.wiki with AI from the original and checked against quotes from it; it can still be wrong. Read the original before relying on a detail.
Not written yet. The AI write-up for this write-up has not been written yet. The Original tab links to the source.
This report describes a server-side request forgery (SSRF) bug in Ivanti Connect Secure's SAML handling. SSRF lets an attacker trick the server into making requests to internal services that are not normally reachable from the internet. The researchers used this to reach an internal API and then run commands on the device.
What is SSRF?
The server can be made to fetch an address the attacker chooses, reaching internal services, cloud metadata or other customers' data.