SiteGround Optimizer <= 5.0.12 - Missing Authorization

Missing Authorization
CVSS 9.8 (Critical)
Publicly Published March 14, 2019
Last Updated February 1, 2023
Researcher Marc-Alexandre Montpas - Sucuri


The SiteGround Optimizer plugin for WordPress is vulnerable to authorization bypass leading to Remote Code Execution and Local File Inclusion in versions up to, and including, 5.0.12 due to incorrect use of an access control attribute on the switch_php function called via the /switch-php REST API route. This allows attackers to include and execute arbitrary files on the server, allowing the execution of any PHP code in those files. This can be used to bypass access controls, obtain sensitive data, or achieve code execution in cases where images and other “safe” file types can be uploaded and included.

Wordfence blocked 2,117 attacks targeting this vulnerability in the past 24 hours.



Vulnerability Details for Speed Optimizer – The All-In-One Performance-Boosting Plugin

Software Type Plugin
Software Slug sg-cachepress (view on
Patched? Yes
Remediation Update to version 5.0.13, or a newer patched version
Affected Version
  • < 5.0.13
Patched Version
  • 5.0.13

Did you know Wordfence Intelligence provides free personal and commercial API access to our comprehensive WordPress vulnerability database, along with a free webhook integration to stay on top of the latest vulnerabilities added and updated in the database? Get started today!

Learn more

Want to get notified of the latest vulnerabilities that may affect your WordPress site?
Install Wordfence on your site today to get notified immediately if your site is affected by a vulnerability that has been added to our database.

Get Wordfence

The Wordfence Intelligence WordPress vulnerability database is completely free to access and query via API. Please review the documentation on how to access and consume the vulnerability data via API.