YunoHost-Apps/wekan_ynh

Login problem

Closed this issue · 7 comments

Describe the bug
A clear and concise description of what the bug is.

Versions

  • Hardware: Old laptop
  • YunoHost version: 4.0.8.3
  • I have access to my server: Through SSH , through the webadmin, direct access via keyboard / screen
  • Are you in a special context or did you perform some particular tweaking on your YunoHost instance ?: no
  • Using, or trying to install package version/branch: 4.64~ynh1

To Reproduce
Steps to reproduce the behavior.

  1. Login with user bde on the user panel (sntec.fr)
  2. Click en Wekan application
  3. I arrive at the page welcome page (see attachment)
  4. Unable to connect with neither password nor LDAP authentication
    Capture d’écran 2020-12-29 173216

Expected behavior
4. click on "se connecter" and get connected

Logs
None to provide because I don't know what could help. Let me know if you need any.

I found a fix to this issue (for a fresh install of wekan).

  • Connect as root on your server
  • Disable LDAP auth by editing the file /var/www/wekan/.env and setting the key LDAP_ENABLE to false
  • Restart wekan service : systemctl restart wekan
  • Connect to the database : mongo wekan
  • List users in the database : db.users.find().toArray()
  • For each user delete it using this command : db.users.remove( {"username": "$username"})
  • Go to web interface, you will see the sign-in page
  • Create your user (you possibly will have the error message "Internal server error", but the user is correctly created)
  • If everything working well you can login sucessfully
SiM commented

Hi,
Same problem here.
After some tests, it appears that it may only concern YNH users with more than one email address.

Tested on a fresh Wekan install on YNH 4.1.7.4

  • Try to log in with an user who has several mail aliases: not possible (same result as the image posted by @bdelaup in his first message)
  • Try to log in with an user who has only one email address: it works
  • Try to log in with same user after added one mail alias: not possible

Here is the error that appears in journalctl:
Exception while invoking method 'login' RangeError: Maximum call stack size exceeded

This is what it's logged when a user have mail aliases.

Apr  2 10:12:53 ***** wekan[31621]: [DEBUG] fullname= "***** *****"
Apr  2 10:12:53 ***** wekan[31621]: [INFO] Syncing user fullname: "***** *****"
Apr  2 10:12:53 ***** wekan[31621]: [DEBUG] email= [
Apr  2 10:12:53 ***** wekan[31621]:   {
Apr  2 10:12:53 ***** wekan[31621]:     "type": "Buffer",
Apr  2 10:12:53 ***** wekan[31621]:     "data": [
Apr  2 10:12:53 ***** wekan[31621]:       103,
Apr  2 10:12:53 ***** wekan[31621]:       110,
Apr  2 10:12:53 ***** wekan[31621]:       117,
Apr  2 10:12:53 ***** wekan[31621]:       114,
Apr  2 10:12:53 ***** wekan[31621]:       97,
Apr  2 10:12:53 ***** wekan[31621]:       103,
Apr  2 10:12:53 ***** wekan[31621]:       105,
Apr  2 10:12:53 ***** wekan[31621]:       115,
Apr  2 10:12:53 ***** wekan[31621]:       116,
Apr  2 10:12:53 ***** wekan[31621]:       101,
Apr  2 10:12:53 ***** wekan[31621]:       115,
Apr  2 10:12:53 ***** wekan[31621]:       64,
Apr  2 10:12:53 ***** wekan[31621]:       97,
Apr  2 10:12:53 ***** wekan[31621]:       97,
Apr  2 10:12:53 ***** wekan[31621]:       100,
Apr  2 10:12:53 ***** wekan[31621]:       116,
Apr  2 10:12:53 ***** wekan[31621]:       112,
Apr  2 10:12:53 ***** wekan[31621]:       46,
Apr  2 10:12:53 ***** wekan[31621]:       98,
Apr  2 10:12:53 ***** wekan[31621]:       101
Apr  2 10:12:53 ***** wekan[31621]:     ]
Apr  2 10:12:53 ***** wekan[31621]:   },
Apr  2 10:12:53 ***** wekan[31621]:   {
Apr  2 10:12:53 ***** wekan[31621]:     "type": "Buffer",
Apr  2 10:12:53 ***** wekan[31621]:     "data": [
Apr  2 10:12:53 ***** wekan[31621]:       114,
Apr  2 10:12:53 ***** wekan[31621]:       111,
Apr  2 10:12:53 ***** wekan[31621]:       111,
Apr  2 10:12:53 ***** wekan[31621]:       116,
Apr  2 10:12:53 ***** wekan[31621]:       64,
Apr  2 10:12:53 ***** wekan[31621]:       97,
Apr  2 10:12:53 ***** wekan[31621]:       97,
Apr  2 10:12:53 ***** wekan[31621]:       100,
Apr  2 10:12:53 ***** wekan[31621]:       116,
Apr  2 10:12:53 ***** wekan[31621]:       112,
Apr  2 10:12:53 ***** wekan[31621]:       46,
Apr  2 10:12:53 ***** wekan[31621]:       98,
Apr  2 10:12:53 ***** wekan[31621]:       101
Apr  2 10:12:53 ***** wekan[31621]:     ]
Apr  2 10:12:53 ***** wekan[31621]:   },
Apr  2 10:12:53 ***** wekan[31621]:   {
Apr  2 10:12:53 ***** wekan[31621]:     "type": "Buffer",
Apr  2 10:12:53 ***** wekan[31621]:     "data": [
Apr  2 10:12:53 ***** wekan[31621]:       119,
Apr  2 10:12:53 ***** wekan[31621]:       101,
Apr  2 10:12:53 ***** wekan[31621]:       98,
Apr  2 10:12:53 ***** wekan[31621]:       109,
Apr  2 10:12:53 ***** wekan[31621]:       97,
Apr  2 10:12:53 ***** wekan[31621]:       115,
Apr  2 10:12:53 ***** wekan[31621]:       116,
Apr  2 10:12:53 ***** wekan[31621]:       101,
Apr  2 10:12:53 ***** wekan[31621]:       114,
Apr  2 10:12:53 ***** wekan[31621]:       64,
Apr  2 10:12:53 ***** wekan[31621]:       97,
Apr  2 10:12:53 ***** wekan[31621]:       97,
Apr  2 10:12:53 ***** wekan[31621]:       100,
Apr  2 10:12:53 ***** wekan[31621]:       116,
Apr  2 10:12:53 ***** wekan[31621]:       112,
Apr  2 10:12:53 ***** wekan[31621]:       46,
Apr  2 10:12:53 ***** wekan[31621]:       98,
Apr  2 10:12:53 ***** wekan[31621]:       101
Apr  2 10:12:53 ***** wekan[31621]:     ]
Apr  2 10:12:53 ***** wekan[31621]:   },
Apr  2 10:12:53 ***** wekan[31621]:   {
Apr  2 10:12:53 ***** wekan[31621]:     "type": "Buffer",
Apr  2 10:12:53 ***** wekan[31621]:     "data": [
Apr  2 10:12:53 ***** wekan[31621]:       112,
Apr  2 10:12:53 ***** wekan[31621]:       111,
Apr  2 10:12:53 ***** wekan[31621]:       115,
Apr  2 10:12:53 ***** wekan[31621]:       116,
Apr  2 10:12:53 ***** wekan[31621]:       109,
Apr  2 10:12:53 ***** wekan[31621]:       97,
Apr  2 10:12:53 ***** wekan[31621]:       115,
Apr  2 10:12:53 ***** wekan[31621]:       116,
Apr  2 10:12:53 ***** wekan[31621]:       101,
Apr  2 10:12:53 ***** wekan[31621]:       114,
Apr  2 10:12:53 ***** wekan[31621]:       64,
Apr  2 10:12:53 ***** wekan[31621]:       97,
Apr  2 10:12:53 ***** wekan[31621]:       97,
Apr  2 10:12:53 ***** wekan[31621]:       100,
Apr  2 10:12:53 ***** wekan[31621]:       116,
Apr  2 10:12:53 ***** wekan[31621]:       112,
Apr  2 10:12:53 ***** wekan[31621]:       46,
Apr  2 10:12:53 ***** wekan[31621]:       98,
Apr  2 10:12:53 ***** wekan[31621]:       101
Apr  2 10:12:53 ***** wekan[31621]:     ]
Apr  2 10:12:53 ***** wekan[31621]:   }
Apr  2 10:12:53 ***** wekan[31621]: ]
Apr  2 10:12:53 ***** wekan[31621]: [INFO] Syncing user email: [
Apr  2 10:12:53 ***** wekan[31621]:   {
Apr  2 10:12:53 ***** wekan[31621]:     "type": "Buffer",
Apr  2 10:12:53 ***** wekan[31621]:     "data": [
Apr  2 10:12:53 ***** wekan[31621]:       103,
Apr  2 10:12:53 ***** wekan[31621]:       110,
Apr  2 10:12:53 ***** wekan[31621]:       117,
Apr  2 10:12:53 ***** wekan[31621]:       114,
Apr  2 10:12:53 ***** wekan[31621]:       97,
Apr  2 10:12:53 ***** wekan[31621]:       103,
Apr  2 10:12:53 ***** wekan[31621]:       105,
Apr  2 10:12:53 ***** wekan[31621]:       115,
Apr  2 10:12:53 ***** wekan[31621]:       116,
Apr  2 10:12:53 ***** wekan[31621]:       101,
Apr  2 10:12:53 ***** wekan[31621]:       115,
Apr  2 10:12:53 ***** wekan[31621]:       64,
Apr  2 10:12:53 ***** wekan[31621]:       97,
Apr  2 10:12:53 ***** wekan[31621]:       97,
Apr  2 10:12:53 ***** wekan[31621]:       100,
Apr  2 10:12:53 ***** wekan[31621]:       116,
Apr  2 10:12:53 ***** wekan[31621]:       112,
Apr  2 10:12:53 ***** wekan[31621]:       46,
Apr  2 10:12:53 ***** wekan[31621]:       98,
Apr  2 10:12:53 ***** wekan[31621]:       101
Apr  2 10:12:53 ***** wekan[31621]:     ]
Apr  2 10:12:53 ***** wekan[31621]:   },
Apr  2 10:12:53 ***** wekan[31621]:   {
Apr  2 10:12:53 ***** wekan[31621]:     "type": "Buffer",
Apr  2 10:12:53 ***** wekan[31621]:     "data": [
Apr  2 10:12:53 ***** wekan[31621]:       114,
Apr  2 10:12:53 ***** wekan[31621]:       111,
Apr  2 10:12:53 ***** wekan[31621]:       111,
Apr  2 10:12:53 ***** wekan[31621]:       116,
Apr  2 10:12:53 ***** wekan[31621]:       64,
Apr  2 10:12:53 ***** wekan[31621]:       97,
Apr  2 10:12:53 ***** wekan[31621]:       97,
Apr  2 10:12:53 ***** wekan[31621]:       100,
Apr  2 10:12:53 ***** wekan[31621]:       116,
Apr  2 10:12:53 ***** wekan[31621]:       112,
Apr  2 10:12:53 ***** wekan[31621]:       46,
Apr  2 10:12:53 ***** wekan[31621]:       98,
Apr  2 10:12:53 ***** wekan[31621]:       101
Apr  2 10:12:53 ***** wekan[31621]:     ]
Apr  2 10:12:53 ***** wekan[31621]:   },
Apr  2 10:12:53 ***** wekan[31621]:   {
Apr  2 10:12:53 ***** wekan[31621]:     "type": "Buffer",
Apr  2 10:12:53 ***** wekan[31621]:     "data": [
Apr  2 10:12:53 ***** wekan[31621]:       119,
Apr  2 10:12:53 ***** wekan[31621]:       101,
Apr  2 10:12:53 ***** wekan[31621]:       98,
Apr  2 10:12:53 ***** wekan[31621]:       109,
Apr  2 10:12:53 ***** wekan[31621]:       97,
Apr  2 10:12:53 ***** wekan[31621]:       115,
Apr  2 10:12:53 ***** wekan[31621]:       116,
Apr  2 10:12:53 ***** wekan[31621]:       101,
Apr  2 10:12:53 ***** wekan[31621]:       114,
Apr  2 10:12:53 ***** wekan[31621]:       64,
Apr  2 10:12:53 ***** wekan[31621]:       97,
Apr  2 10:12:53 ***** wekan[31621]:       97,
Apr  2 10:12:53 ***** wekan[31621]:       100,
Apr  2 10:12:53 ***** wekan[31621]:       116,
Apr  2 10:12:53 ***** wekan[31621]:       112,
Apr  2 10:12:53 ***** wekan[31621]:       46,
Apr  2 10:12:53 ***** wekan[31621]:       98,
Apr  2 10:12:53 ***** wekan[31621]:       101
Apr  2 10:12:53 ***** wekan[31621]:     ]
Apr  2 10:12:53 ***** wekan[31621]:   },
Apr  2 10:12:53 ***** wekan[31621]:   {
Apr  2 10:12:53 ***** wekan[31621]:     "type": "Buffer",
Apr  2 10:12:53 ***** wekan[31621]:     "data": [
Apr  2 10:12:53 ***** wekan[31621]:       112,
Apr  2 10:12:53 ***** wekan[31621]:       111,
Apr  2 10:12:53 ***** wekan[31621]:       115,
Apr  2 10:12:53 ***** wekan[31621]:       116,
Apr  2 10:12:53 ***** wekan[31621]:       109,
Apr  2 10:12:53 ***** wekan[31621]:       97,
Apr  2 10:12:53 ***** wekan[31621]:       115,
Apr  2 10:12:53 ***** wekan[31621]:       116,
Apr  2 10:12:53 ***** wekan[31621]:       101,
Apr  2 10:12:53 ***** wekan[31621]:       114,
Apr  2 10:12:53 ***** wekan[31621]:       64,
Apr  2 10:12:53 ***** wekan[31621]:       97,
Apr  2 10:12:53 ***** wekan[31621]:       97,
Apr  2 10:12:53 ***** wekan[31621]:       100,
Apr  2 10:12:53 ***** wekan[31621]:       116,
Apr  2 10:12:53 ***** wekan[31621]:       112,
Apr  2 10:12:53 ***** wekan[31621]:       46,
Apr  2 10:12:53 ***** wekan[31621]:       98,
Apr  2 10:12:53 ***** wekan[31621]:       101
Apr  2 10:12:53 ***** wekan[31621]:     ]
Apr  2 10:12:53 ***** wekan[31621]:   }
Apr  2 10:12:53 ***** wekan[31621]: ]
Apr  2 10:12:54 ***** wekan[31621]: Exception while invoking method 'login' RangeError: Maximum call stack size exceeded
Apr  2 10:12:54 ***** wekan[31621]:     at EJSON.clone (packages/ejson/ejson.js:551:15)
Apr  2 10:12:54 ***** wekan[31621]:     at Array.map (<anonymous>)
Apr  2 10:12:54 ***** wekan[31621]:     at Object.EJSON.clone (packages/ejson/ejson.js:580:14)
Apr  2 10:12:54 ***** wekan[31621]:     at packages/ejson/ejson.js:600:22
Apr  2 10:12:54 ***** wekan[31621]:     at Array.forEach (<anonymous>)
Apr  2 10:12:54 ***** wekan[31621]:     at Object.EJSON.clone (packages/ejson/ejson.js:599:13)
Apr  2 10:12:54 ***** wekan[31621]:     at packages/ejson/ejson.js:600:22
Apr  2 10:12:54 ***** wekan[31621]:     at Array.forEach (<anonymous>)
Apr  2 10:12:54 ***** wekan[31621]:     at Object.EJSON.clone (packages/ejson/ejson.js:599:13)
Apr  2 10:12:54 ***** wekan[31621]:     at packages/ejson/ejson.js:600:22
Apr  2 10:12:54 ***** wekan[31621]:     at Array.forEach (<anonymous>)
Apr  2 10:12:54 ***** wekan[31621]:     at Object.EJSON.clone (packages/ejson/ejson.js:599:13)
Apr  2 10:12:54 ***** wekan[31621]:     at packages/ejson/ejson.js:600:22
Apr  2 10:12:54 ***** wekan[31621]:     at Array.forEach (<anonymous>)
Apr  2 10:12:54 ***** wekan[31621]:     at Object.EJSON.clone (packages/ejson/ejson.js:599:13)
Apr  2 10:12:54 ***** wekan[31621]:     at packages/ejson/ejson.js:600:22
Apr  2 10:12:54 ***** wekan[31621]:     at Array.forEach (<anonymous>)
Apr  2 10:12:54 ***** wekan[31621]:     at Object.EJSON.clone (packages/ejson/ejson.js:599:13)
Apr  2 10:12:54 ***** wekan[31621]:     at packages/ejson/ejson.js:600:22
Apr  2 10:12:54 ***** wekan[31621]:     at Array.forEach (<anonymous>)
Apr  2 10:12:54 ***** wekan[31621]:     at Object.EJSON.clone (packages/ejson/ejson.js:599:13)
Apr  2 10:12:54 ***** wekan[31621]:     at packages/ejson/ejson.js:600:22
Apr  2 10:12:54 ***** wekan[31621]:     at Array.forEach (<anonymous>)
Apr  2 10:12:54 ***** wekan[31621]:     at Object.EJSON.clone (packages/ejson/ejson.js:599:13)
Apr  2 10:12:54 ***** wekan[31621]:     at packages/ejson/ejson.js:600:22
Apr  2 10:12:54 ***** wekan[31621]:     at Array.forEach (<anonymous>)
Apr  2 10:12:54 ***** wekan[31621]:     at Object.EJSON.clone (packages/ejson/ejson.js:599:13)
Apr  2 10:12:54 ***** wekan[31621]:     at packages/ejson/ejson.js:600:22
Apr  2 10:12:54 ***** wekan[31621]:     at Array.forEach (<anonymous>)
Apr  2 10:12:54 ***** wekan[31621]:     at Object.EJSON.clone (packages/ejson/ejson.js:599:13)
Apr  2 10:12:54 ***** wekan[31621]:     at packages/ejson/ejson.js:600:22
Apr  2 10:12:54 ***** wekan[31621]:     at Array.forEach (<anonymous>)
Apr  2 10:12:54 ***** wekan[31621]:     at Object.EJSON.clone (packages/ejson/ejson.js:599:13)
Apr  2 10:12:54 ***** wekan[31621]:     at packages/ejson/ejson.js:600:22
Apr  2 10:13:03 ***** wekan[31621]: [INFO] Idle
Apr  2 10:13:03 ***** wekan[31621]: [INFO] Disconecting

This is what is logged when a user have no mail aliases.

Apr  2 10:15:53 ***** wekan[31621]: [DEBUG] fullname= "*** ****"
Apr  2 10:15:53 ***** wekan[31621]: [INFO] Syncing user fullname: "**** ****"
Apr  2 10:15:53 ***** wekan[31621]: [DEBUG] email= "*****@***.**"
Apr  2 10:15:53 ***** wekan[31621]: [INFO] Syncing user email: "*****@***.**"
Apr  2 10:16:03 ***** wekan[31621]: [INFO] Idle
Apr  2 10:16:03 ***** wekan[31621]: [INFO] Disconecting
SiM commented

The problem is still present with Wekan 5.17 and YNH 4.1.8

@datatierce my logs looks like yours.

Hi,

Same problem here with a fresh install of Wekan on YNH 4.1.8, user with Wekan Admin group and several mail aliases.

+1 can't log in, event got Internal server error on registration new user