CVE-2025-31404

7.1 HIGH

📋 TL;DR

This CSRF vulnerability in the AF Tell a Friend WordPress plugin allows attackers to trick authenticated administrators into executing malicious actions, leading to stored cross-site scripting (XSS). Attackers can inject persistent malicious scripts that execute in victims' browsers when viewing affected pages. All WordPress sites using AF Tell a Friend plugin versions up to 1.4 are affected.

💻 Affected Systems

Products:
  • AF Tell a Friend WordPress Plugin
Versions: n/a through 1.4
Operating Systems: Any OS running WordPress
Default Config Vulnerable: ⚠️ Yes
Notes: Requires WordPress installation with the AF Tell a Friend plugin enabled. The vulnerability requires an authenticated administrator to be tricked into visiting a malicious page.

⚠️ Manual Verification Required

This CVE does not have specific version information in our database, so automatic vulnerability detection cannot determine if your system is affected.

Why? The CVE database entry doesn't specify which versions are vulnerable (no version ranges provided by the vendor/NVD).

🔒 Custom verification scripts are available for registered users. Sign up free to download automated test scripts.

Recommended Actions:
  1. Review the CVE details at NVD
  2. Check vendor security advisories for your specific version
  3. Test if the vulnerability is exploitable in your environment
  4. Consider updating to the latest version as a precaution

⚠️ Risk & Real-World Impact

🔴

Worst Case

Attackers could inject malicious JavaScript that steals administrator credentials, redirects users to malicious sites, or performs unauthorized administrative actions, potentially leading to complete site compromise.

🟠

Likely Case

Attackers inject malicious scripts that execute in users' browsers, potentially stealing session cookies, performing actions on behalf of users, or defacing the website.

🟢

If Mitigated

With proper CSRF protections and input validation, the attack chain would be broken, preventing both the CSRF and subsequent XSS exploitation.

🌐 Internet-Facing: HIGH
🏢 Internal Only: MEDIUM

🎯 Exploit Status

Public PoC: ✅ No
Weaponized: LIKELY
Unauthenticated Exploit: ✅ No
Complexity: LOW

Exploitation requires social engineering to trick an authenticated administrator into clicking a malicious link. The CSRF leads to stored XSS, making the attack persistent.

🛠️ Fix & Mitigation

✅ Official Fix

Patch Version: 1.5 or later

Vendor Advisory: https://patchstack.com/database/wordpress/plugin/af-tell-a-friend/vulnerability/wordpress-af-tell-a-friend-plugin-1-4-csrf-to-stored-xss-vulnerability?_s_id=cve

Restart Required: No

Instructions:

1. Log into WordPress admin panel. 2. Navigate to Plugins > Installed Plugins. 3. Find 'AF Tell a Friend' and check if update is available. 4. Click 'Update Now' or manually update to version 1.5+. 5. Verify plugin is active and functioning.

🔧 Temporary Workarounds

Disable Plugin

all

Temporarily disable the vulnerable plugin until patched

wp plugin deactivate af-tell-a-friend

Implement CSRF Protection

all

Add CSRF tokens to plugin forms via custom code or security plugin

🧯 If You Can't Patch

  • Remove the AF Tell a Friend plugin completely from the WordPress installation
  • Implement web application firewall (WAF) rules to block CSRF attempts and XSS payloads targeting the plugin endpoints

🔍 How to Verify

Check if Vulnerable:

Check WordPress admin panel > Plugins > Installed Plugins, find AF Tell a Friend and verify version is 1.4 or earlier

Check Version:

wp plugin get af-tell-a-friend --field=version

Verify Fix Applied:

Verify plugin version is 1.5 or later in WordPress admin panel, and test that the 'Tell a Friend' functionality works without security warnings

📡 Detection & Monitoring

Log Indicators:

  • Unusual POST requests to /wp-admin/admin-ajax.php or plugin-specific endpoints
  • Multiple failed CSRF token validations in WordPress debug logs
  • Unexpected JavaScript injection in database content fields

Network Indicators:

  • HTTP requests with suspicious parameters to plugin endpoints from unexpected referrers
  • Patterns of requests that bypass normal user workflow

SIEM Query:

source="wordpress.log" AND ("af-tell-a-friend" OR "admin-ajax.php") AND (POST AND NOT "_wpnonce")

🔗 References

📤 Share & Export