FabriXss (CVE-2022-35829): How We Managed to Abuse a Custom Role User Using CSTI and Stored XSS in Azure Fabric Explorer
A user with a custom Deployer role could create an application with a malicious name that executed as a client-side template injection and then stored cross-site scripting in the Service Fabric Explorer dashboard. When an administrator viewed the dashboard, the injected script ran with the administrator's privileges, allowing the attacker to restart a cluster node and potentially gain full administrator access.
Published on orca.security
FabriXss (pronounced like ‘fabrics’) is a vulnerability discovered by the Orca Research Pod that resides in Azure Service Fabric Explorer (SFX), and allows an attacker to gain full Administrator permissions on the Service Fabric cluster.
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 application name was rendered through an AngularJS template and then inserted into the page without proper sanitisation, allowing template expressions and HTML to execute.
Impact
An attacker with a Deployer role could execute arbitrary JavaScript in an administrator's browser and perform privileged actions such as restarting a cluster node, potentially leading to full administrator access to the cluster.
What the attacker needed
A Deployer role with permission to create applications; victim (admin) views the dashboard; attacker can host a remote file
The fix
Microsoft released a fix in the October 2022 Patch Tuesday and recommends using SFXv2 with a URL ending in index.html instead of the vulnerable old.html.
How it was found
- As a Deployer user, create a new application with a name containing a crafted template expression.
- Refresh the application list in the dashboard to trigger execution of the template expression.
- Craft a payload that breaks out of the application name context and injects an image tag with an error handler.
- Host a hook HTML file on a remote server that sends a fetch request to the node restart API endpoint.
- Send the stored XSS payload as the application name via the API, then refresh the dashboard.
- When an administrator views the dashboard, the payload executes and the hook file causes a node restart request with the administrator's credentials.
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.
Service Fabric Explorer is a web dashboard for managing a cluster. A user with limited rights could give an application a name containing special code. The dashboard displayed that name without proper cleaning, so the code ran in the browser of anyone who viewed the dashboard, including administrators. That let the attacker make the administrator's browser send commands to the cluster.
What is XSS?
Script an attacker supplies runs in another user's browser, on the target's origin, with that user's session.