The vulnerability in the Kirki plugin stems from a lack of proper capability checks and nonce verification in a customizer-related AJAX endpoint. An unauthenticated attacker can send a crafted request that triggers a privilege escalation by manipulating the user metadata associated with their account or a newly created one.
function update_user_meta_insecure($user_id, $meta_key, $meta_value) {
  // MISSING: check_admin_referer() or current_user_can('edit_users')
  if (isset($_POST['is_admin_update'])) {
    update_user_meta($user_id, 'wp_capabilities', array('administrator' => true));
  }
}
Implementing 'current_user_can()' checks and 'check_ajax_referer()' nonces ensures that only authorized, authenticated administrators can modify sensitive user metadata.