The WP Maps – Store Locator,Google Maps,OpenStreetMap,Mapbox,Listing,Directory & Filters plugin for WordPress is vulnerable to Stored Cross-Site Scripting via the 'put_wpgm' shortcode in all versions up to, and including, 4.8.7. This is due to insufficient input sanitization and output escaping on user-supplied shortcode attributes. This makes it possible for authenticated attackers, with contributor level access and above, to inject arbitrary web scripts in pages that will execute whenever a user accesses an injected page.
WP Maps plugin versions up to 4.8.7 contain a Stored XSS vulnerability in the 'put_wpgm' shortcode allowing authenticated contributors to inject malicious scripts. The vulnerability affects WordPress sites using this popular mapping plugin, with no patch currently available. Organizations must implement immediate compensating controls and monitor for exploitation.
IMMEDIATE ACTIONS:
1. Audit all WordPress installations for WP Maps plugin presence and current version
2. Restrict contributor-level user access to only trusted personnel; review existing contributor accounts
3. Disable the 'put_wpgm' shortcode if not actively used via plugin settings or code modification
4. Implement Web Application Firewall (WAF) rules to detect and block XSS payloads in shortcode attributes
PATCHING GUIDANCE:
1. Monitor plugin repository for security updates; upgrade immediately when patch is released
2. Contact plugin developer for security advisory timeline
3. Consider alternative mapping plugins with better security track record if patch timeline is unclear
COMPENSATING CONTROLS:
1. Implement Content Security Policy (CSP) headers to restrict inline script execution
2. Enable WordPress security plugins (Wordfence, Sucuri) with XSS detection rules
3. Restrict page/post editing capabilities to administrators only; remove contributor edit permissions
4. Implement output escaping on all shortcode rendering via custom code: wp_kses_post() or wp_kses_data()
5. Enable WordPress audit logging to track shortcode usage and modifications
DETECTION RULES:
1. Monitor database for 'put_wpgm' shortcodes containing script tags or event handlers
2. Alert on contributor-level user account creation or privilege escalation
3. Log all shortcode attribute modifications in posts/pages
4. Search for patterns: [put_wpgm.*on[a-z]+= or [put_wpgm.*<script
الإجراءات الفورية:
1. تدقيق جميع تثبيتات WordPress للتحقق من وجود مكون WP Maps والإصدار الحالي
2. تقييد وصول المستخدمين على مستوى المساهم للموظفين الموثوقين فقط؛ مراجعة حسابات المساهمين الحالية
3. تعطيل اختصار 'put_wpgm' إذا لم يكن قيد الاستخدام النشط عبر إعدادات المكون أو تعديل الكود
4. تنفيذ قواعد جدار حماية تطبيقات الويب (WAF) للكشف عن حقن XSS وحجبها في سمات الاختصار
إرشادات التصحيح:
1. مراقبة مستودع المكون للتحديثات الأمنية؛ الترقية فوراً عند إصدار التصحيح
2. التواصل مع مطور المكون بشأن الجدول الزمني للمشورة الأمنية
3. النظر في مكونات خريطة بديلة بسجل أمان أفضل إذا كان الجدول الزمني للتصحيح غير واضح
الضوابط التعويضية:
1. تنفيذ رؤوس سياسة أمان المحتوى (CSP) لتقييد تنفيذ النصوص البرمجية المضمنة
2. تفعيل مكونات أمان WordPress (Wordfence, Sucuri) مع قواعد كشف XSS
3. تقييد قدرات تحرير الصفحات/المنشورات للمسؤولين فقط؛ إزالة أذونات تحرير المساهم
4. تنفيذ الهروب من الإخراج على جميع عمليات عرض الاختصار عبر الكود المخصص: wp_kses_post() أو wp_kses_data()
5. تفعيل تسجيل تدقيق WordPress لتتبع استخدام الاختصار والتعديلات
قواعد الكشف:
1. مراقبة قاعدة البيانات للبحث عن اختصارات 'put_wpgm' تحتوي على علامات نصية أو معالجات أحداث
2. التنبيه عند إنشاء حساب مستخدم على مستوى المساهم أو تصعيد الامتيازات
3. تسجيل جميع تعديلات سمات الاختصار في المنشورات/الصفحات
4. البحث عن الأنماط: [put_wpgm.*on[a-z]+= أو [put_wpgm.*<script