XenForo <= 2.2.15 (Widget::actionSave) Cross-Site Request Forgery Vulnerability
The widget save action in the XenForo admin controller does not verify the HTTP method before saving, and anti-CSRF checks only apply to POST requests. An attacker could use a GET-based CSRF attack to create or modify widgets, and chain this with another issue to achieve remote code execution.
karmainsecurity.com
Published on karmainsecurity.com
The XF\Admin\Controller\Widget::actionSave() method, defined into the /src/XF/Admin/Controller/Widget.php script, does not check whether the current HTTP request is a POST or a GET before saving a widget. XenForo does perform anti-CSRF checks for POST requests only, as such this method can be abused in a Cross-Site…
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
The controller action did not enforce the POST method, and the anti-CSRF protection was only applied to POST requests, leaving GET requests unprotected.
Impact
An attacker could create or modify arbitrary widgets through CSRF, and could potentially chain this with another vulnerability to achieve remote code execution.
What the attacker needed
Victim is a logged-in admin; victim visits attacker-controlled page; attacker knows the target widget action
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.
A website normally protects actions like saving settings by requiring a secret token that only the real site can include. Here, the save action accepted a simple link-style request (GET) without that token check, so a malicious page could make a logged-in administrator's browser save a widget without them knowing. The report also says this could be combined with another bug to run code on the server.
What is CSRF?
Another site makes a signed-in user's browser perform an action they did not intend.