iZooto <= 3.7.20 - Missing Authorization
Description
The iZooto plugin for WordPress is vulnerable to unauthorized access due to a missing capability check on a function in versions up to, and including, 3.7.20. This makes it possible for unauthenticated attackers to perform an unauthorized action.
CVSS Vector Breakdown
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:L/A:NTechnical Details
<=3.7.20This research plan outlines the process for identifying and exploiting a missing authorization vulnerability in the **iZooto – Web Push Notifications** plugin (versions <= 3.7.20). ### 1. Vulnerability Summary The iZooto plugin fails to implement proper capability checks on certain AJAX or initiali…
Show full research plan
This research plan outlines the process for identifying and exploiting a missing authorization vulnerability in the iZooto – Web Push Notifications plugin (versions <= 3.7.20).
1. Vulnerability Summary
The iZooto plugin fails to implement proper capability checks on certain AJAX or initialization handlers. This "Missing Authorization" vulnerability allows unauthenticated attackers to invoke functions that were intended for administrative use, potentially leading to unauthorized modification of plugin settings, such as the iZooto App ID or integration keys.
2. Attack Vector Analysis
- Endpoint:
wp-admin/admin-ajax.phpor a hook onadmin_init/init. - Action (Inferred): Likely
iz_save_settings,izooto_save_settings, orsync_izooto_settings. - Payload Parameter:
action,nonce(if applicable), and setting fields likeizooto_app_id. - Authentication: Unauthenticated (as per the vulnerability description).
- Preconditions: The plugin must be active.
3. Code Flow (Inferred)
- The plugin registers an AJAX action or an
admin_inithook in the main plugin file or an includes class (e.g.,izooto.phporincludes/class-izooto.php). - Entry Point: An unauthenticated request is sent to
admin-ajax.php?action=[VULNERABLE_ACTION]. - Missing Check: The handler function (e.g.,
iz_save_settings()) is invoked. It likely lacks acurrent_user_can( 'manage_options' )check. - Sink: The function processes user-supplied input from
$_POSTand passes it toupdate_option(), allowing settings to be overwritten.
4. Nonce Acquisition Strategy
To determine if a nonce is required and how to obtain it:
- Locate Registration: Search for the action registration:
grep -rn "wp_ajax_" . - Analyze Handler: Check if the handler uses
check_ajax_referer()orwp_verify_nonce(). - Identify Localization: If a nonce is required, find where it is passed to the frontend:
grep -rn "wp_localize_script" . - Extraction:
- Identify the script handle and the object name (e.g.,
izooto_ajax_obj). - Find which page enqueues this script (typically the plugin settings page, but sometimes the public frontend for subscriber tracking).
- If available on the frontend, create a post/page to trigger the script if necessary:
wp post create --post_type=page --post_status=publish --post_content='[izooto_shortcode]'(Verify actual shortcode name viagrep -r "add_shortcode" .). - Navigate to the page using
browser_navigate. - Execute:
browser_eval("window.izooto_ajax_obj?.nonce")(Replaceizooto_ajax_objandnoncewith the actual keys found in the code).
- Identify the script handle and the object name (e.g.,
5. Exploitation Strategy
The goal is to modify the plugin's configuration unauthenticated.
- Discovery: Use the following to find the exact vulnerable action and parameter:
grep -rnE "update_option|update_site_option" . -A 5 | grep -B 5 "wp_ajax" - Target Settings: Identify the option name used to store the iZooto App ID (likely
izooto_settingsoriz_app_id). - HTTP Request (Example):
- Method:
POST - URL:
http://localhost:8080/wp-admin/admin-ajax.php - Headers:
Content-Type: application/x-www-form-urlencoded - Body:
(Note: If the check is entirely missing, the nonce parameter can be omitted or sent as a dummy value.)action=iz_save_settings&iz_app_id=ATTACKER_APP_ID&nonce=[EXTRACTED_NONCE]
- Method:
6. Test Data Setup
- Install and activate iZooto <= 3.7.20.
- Configure a legitimate App ID via the WordPress admin UI initially to establish a baseline:
wp option update izooto_settings '{"app_id":"12345"}'(Example structure). - Identify the required parameters by inspecting the settings form in the admin dashboard.
7. Expected Results
- The server should return a
200 OKor a JSON success response (e.g.,{"success":true}). - The targeted WordPress option (e.g.,
izooto_settings) should be updated with the attacker's value.
8. Verification Steps
After sending the exploit request, verify the state change via WP-CLI:
# Check if the option value has changed
wp option get izooto_settings
Expected output: The data should now reflect the ATTACKER_APP_ID.
9. Alternative Approaches
- Check
admin_initHook: If nowp_ajax_noprivis found, the vulnerability may exist in a function hooked toadmin_init. Sinceadmin_initruns for every request towp-admin/admin-ajax.php(even for unauthenticated users), an unprotected hook here is a common source of "Missing Authorization."- Look for:
add_action( 'admin_init', 'vulnerable_function' ). - Check if
vulnerable_functionprocesses$_POSTwithout checkingcurrent_user_can.
- Look for:
- REST API: Check for registered REST routes:
grep -rn "register_rest_route" .
Inspect thepermission_callback. If it is__return_trueor missing, the endpoint is unauthenticated.
Summary
The iZooto plugin for WordPress is vulnerable to unauthorized access in versions up to and including 3.7.20 due to a missing capability check on administrative functions. This allows unauthenticated attackers to invoke these functions, potentially leading to unauthorized modification of plugin settings such as the App ID and integration keys.
Exploit Outline
1. Identify the vulnerable AJAX action (e.g., 'iz_save_settings') or administrative hook (e.g., 'admin_init') used for updating plugin configuration. 2. Determine the required POST parameters for updating settings, such as 'iz_app_id', by inspecting the plugin's settings page. 3. Verify if a security nonce is required; if so, identify a method to extract it from the public frontend or script localization. 4. Send an unauthenticated POST request to 'wp-admin/admin-ajax.php' containing the vulnerable action and the desired configuration values. 5. Confirm the vulnerability by verifying that the targeted option in the WordPress database (e.g., 'izooto_settings') has been updated with the attacker-supplied value.
Check if your site is affected.
Run a free security audit to detect vulnerable plugins, outdated versions, and misconfigurations.