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

Can't login with administrator account #12185

Closed
arkabase opened this issue Nov 25, 2023 · 3 comments
Closed

Can't login with administrator account #12185

arkabase opened this issue Nov 25, 2023 · 3 comments
Assignees
Labels
Milestone

Comments

@arkabase
Copy link

NodeBB version

v3.5.1

NodeBB git hash

4c54348

NodeJS version

v20.9.0

Installed NodeBB plugins

* nodebb-plugin-2factor@7.4.0 (installed, disabled)
* nodebb-plugin-composer-default@10.2.24 (installed, enabled)
* nodebb-plugin-dbsearch@6.2.2 (installed, disabled)
* nodebb-plugin-emoji@5.1.13 (installed, enabled)
* nodebb-plugin-emoji-android@4.0.0 (installed, enabled)
* nodebb-plugin-markdown@12.2.5 (installed, enabled)
* nodebb-plugin-mentions@4.3.7 (installed, enabled)
* nodebb-plugin-ntfy@1.7.3 (installed, disabled)
* nodebb-plugin-spam-be-gone@2.2.0 (installed, disabled)
* nodebb-rewards-essentials@1.0.0 (installed, enabled)
* nodebb-theme-harmony@1.1.91 (installed, enabled)
* nodebb-theme-lavender@7.1.5 (installed, disabled)
* nodebb-theme-peace@2.1.23 (installed, disabled)
* nodebb-theme-persona@13.2.42 (installed, disabled)
* nodebb-widget-essentials@7.0.14 (installed, enabled)

Database type

MongoDB

Database version

v7.0.3

Exact steps to cause this issue

  1. Install and setup NodeBB as in the documentation
  2. create initial administrrator account
  3. restart NodeBB
  4. login with administrator account

What you expected

The user is logged in and has access to NodeBB admin dashboard

What happened instead

Error message saying identification certificate is invalid.

  • Tried multiple times, same result
  • Changed password using NodeBB CLI, retry, same result
  • Created a new user account, made user admin using NodeBB CLI : user can login but is denied access to admin dashboard.

Anything else?

I can't understand where the user accounts are saved. My Mongo DB has only 2 collections "objects" and "sessions" and none contains user data. Where is NodeBB data stored ???

@arkabase arkabase added the bug label Nov 25, 2023
@julianlam
Copy link
Member

In objects.

Can you show us the error, either copy pasted or screenshot?

@arkabase
Copy link
Author

I finally succeeded to login after changing the password using the password reset email link and the same password as before. Seems that the CLI doesn't set the password correctly, maybe using a wrong secret ?

@barisusakli barisusakli self-assigned this Nov 29, 2023
@barisusakli barisusakli added this to the 3.5.2 milestone Nov 29, 2023
@barisusakli
Copy link
Member

Seems like trying to reset password via cli crashes,

TypeError: Cannot read properties of undefined (reading 'get')
    at D:\github\NodeBB\src\user\auth.js:66:38
    at node:internal/util:411:7
    at new Promise (<anonymous>)
    at node:internal/util:397:12
    at User.auth.revokeSession (D:\github\NodeBB\src\user\auth.js:131:28)
    at Object.wrapperCallback [as revokeSession] (D:\github\NodeBB\src\promisify.js:46:11)
    at D:\github\NodeBB\src\user\auth.js:148:42
    at Array.map (<anonymous>)
    at D:\github\NodeBB\src\user\auth.js:148:23

Will get it fixed for 3.5.2

barisusakli added a commit that referenced this issue Nov 29, 2023
refactor session get/destroy
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants