Topic: How to recover a CN admin account

Please use the script below to create a .php file.

<?php

include dirname(__FILE__) . '/core/init.php';

$user_name   = 'admin3';
$user_email = 'test@test.com';
$user_pass  = 'password';

// Prevent create new user
if (!db_user_by_name($user_name)) {
    db_user_add($user_name, ACL_LEVEL_ADMIN);
}

// Update credentials
db_user_update($user_name, "email=$user_email", 'pass='.SHA256_hash($user_pass));

echo "ADD [$user_name]";
?>

You can name the file the way you like, this isn't important but it should have the .php extension. After naming the created file, insert it into the Сutenews root directory next to CN files (for example cn_api.php and the like). 

When everything mentioned above is done, set the following parameters:
$user_name, $user_email, $user_pass


Run the script from the website.

When the procedure described above is done, delete the script file and log in as you usually do with the new parameters you have set.

Best regards,
CN Support team

Re: How to recover a CN admin account

Administrators should have a spare security key—Administrators should enroll more than one security key for their administrator account and store it in a safe place.
Save backup codes ahead of time—Administrators and users should generate and print backup codes in case they’re needed in the future. Keep backup codes in a secure location.
Set up an additional administrator—If an administrator can’t sign in to their administrator account, another administrator can generate backup codes for them.
If security keys are required, set up a grace period—When you set up 2SV enforcement, define a 2-step verification policy suspension grace period. Users can enter a backup code for 2SV during the grace period.