Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

When authentication method is set to None, change to Builtin as None has been removed #2384

Closed
cigamit opened this issue Feb 8, 2019 · 1 comment
Assignees
Labels
bug Undesired behaviour resolved A fixed issue

Comments

@cigamit
Copy link
Member

cigamit commented Feb 8, 2019

A user recently reported that they were having issues locking and unlocking trees. They had inadvertently set authentication to none. The upgrade was allowed, but the authentication was was not changed to 'builtin' after the upgrade was complete.

This cause an issue that should not have happened.

We should:

  1. Issue a WARNING that authentication will be changed to Builtin
  2. If this warning was set, after the upgrade is complete, redirect them to the logout after they press the 'Get Started' button.
@cigamit cigamit added the bug Undesired behaviour label Feb 8, 2019
@netniV netniV changed the title installer: When upgrading, if Authentication Method is set to None Change to Builtin Installer: When upgrading, if Authentication Method is set to None Change to Builtin Feb 9, 2019
@netniV netniV changed the title Installer: When upgrading, if Authentication Method is set to None Change to Builtin Installer: If current authentication method is set to None, change to Builtin Feb 9, 2019
@netniV netniV changed the title Installer: If current authentication method is set to None, change to Builtin If current authentication method is set to None, change to Builtin Feb 14, 2019
netniV added a commit that referenced this issue Feb 14, 2019
If current authentication method is set to None, change to Builtin.

To achieve this, the code will look for a valid administration user that will be used to reset the password.  This is achieved by searching for the Primary Admin, and then any admin with console access.  Once an admin has been found, the must_change_password and change_password flags are set, the password is cleared and the user is automatically logged in before being forced to change the empty password.

If no admin can be located, the script will die to prevent issues and allow manual fixing of the problem.  The simpliest way to do this would be to utilise the INSERT statement that is used for the 'admin' user in the cacti.sql's user_auth table, plus the INSERT for user_id 1 into the user_auth_realm table.
@netniV
Copy link
Member

netniV commented Feb 14, 2019

To achieve this, the code will look for a valid administration user that will be used to reset the password. This is achieved by searching for the Primary Admin, and then any admin with console access. Once an admin has been found, the must_change_password and change_password flags are set, the password is cleared and the user is automatically logged in before being forced to change the empty password.

If no admin can be located, the script will die to prevent issues and allow manual fixing of the problem. The simpliest way to do this would be to utilise the INSERT statement that is used for the 'admin' user in the cacti.sql's user_auth table, plus the INSERT for user_id 1 into the user_auth_realm table.

@netniV netniV added the resolved A fixed issue label Feb 14, 2019
@netniV netniV closed this as completed Feb 24, 2019
@netniV netniV changed the title If current authentication method is set to None, change to Builtin When authentication method is set to None, change to Builtin as None has been removed Feb 24, 2019
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Jun 30, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug Undesired behaviour resolved A fixed issue
Projects
None yet
Development

No branches or pull requests

2 participants