WordPress: Unauthenticated path traversal leading to conditional RCE
110 points - today at 4:33 PM
SourceComments
zelphirkalt today at 6:06 PM
These are the reason, why every easily reachable web server will be spammed with /something/something.php?somearg=someval. If I had to guess, which software on the web has been the most exploitable over all of the web's history, WP would surely be among the top candidates. Maybe right after MS Teams or Sharepoint or some stuff like that.
random_savv today at 6:33 PM
I am so happy that I asked Codex to rewrite our website as Hugo templates which allowed us to statically host it and get rid of Wordpress. So much stress gone!
chrismorgan today at 6:18 PM
vntok today at 5:18 PM
Ironically, this 9 years old comment on the official documentation page of one of the affected functions perfectly describes both the nature and remediation of this major security flaw:
> Paul Ryan 9 years ago
> Note that locate_template() does not prevent directory traversal attacks, so if you’re passing a user-provided template name to the function, be sure to verify that it’s from one of the three appropriate locations (active theme directory, parent theme directory, or /wp-includes/theme-compat/ directory).
https://developer.wordpress.org/reference/functions/locate_t...
iLoveOncall today at 6:48 PM
WordPress really is a piece of garbage software, and if you've ever developed plugins for it it is soooo apparent.
The documentation is a perfect reflection of the absolute mess of spaghetti code that it is, half of the methods that you will use constantly when developing plugins are undocumented, even untyped. It's literally unusable.
I know WordPress is good thanks to its ecosystem, but really, really, do NOT use it.
whycome today at 5:10 PM
hmm, this may be why i just saw an unexpected update to a very old theme.
system2 today at 4:58 PM
pearcmd.php must exist, and register_argc_argv must be on, not common with hosting providers. But I am assuming the other themes and meeting conditions possibly affect a lot of WordPress sites.
tptacek today at 5:02 PM
[flagged]