WordPress Plugin Paid Business Listings 1.0.2 - Blind SQL Injection








# Exploit Title: WordPress Paid Business Listings v1.0.2 Blind SQL Injection
# Date: 6/29/12
# Exploit Author: Chris Kellum
# Vendor Homepage: http://www.blazingtorch.com/
# Software Link: http://downloads.wordpress.org/plugin/paid-business-listings.1.0.2.zip
# Version: 1.0.2

Plugin Details

This plugin has a 3 stage process, which includes a submission form page, a submission status page, and a business listings page.

The results of the form injection can be determined by viewing whether the listing appears on the business listings page.

Testing Details

When recreating this vulnerability, create a "free listing" package (leave the cost field blank) in the admin panel and select that package when submitting the form.

Free listings are added to the Business Listings page immediately after form submission, so this will allow you to immediately verify how your SQL statement was evaluated.

Vulnerability Details

Input data from the form submission is not properly sanitized.

Using blind SQL injection techniques, true statements will result in the listing appearing on the business listings page, while false statements will not.

Injection Example

Using Burp Suite or other proxy, intercept the post request when submitting the form and add AND 1=1 to the request before forwarding:

&pbl_listing_cat_id=1&pbl_listing_pkg_id=2 AND 1=1

Submission of this request will result in the listing appearing on the business listings page. 

When submitting the request with AND 1=0, the listing will not appear on the business listings page.