Rocket.Chat icon indicating copy to clipboard operation
Rocket.Chat copied to clipboard

Email not verified by clicking verification link

Open robindijkhof opened this issue 8 years ago • 38 comments

Description:

After clicking the verification link the user is redirected to the login page. When the user tries to login it gets a message saying the user is not found or the password is incorrect. When checking as admin, the user is still unverified.

Server Setup Information:

  • Server Setup Information:
  • Version of Rocket.Chat Server: 0.62.2
  • Operating System: Ubuntu 16.04 LTS
  • Deployment Method(snap/docker/tar/etc): Manual install
  • Number of Running Instances: 1
  • DB Replicaset Oplog:
  • Node Version: 8.9.4

Steps to Reproduce:

  1. Configure SMTP (test it)
  2. Enable verification under Email -> verification
  3. Enable verification under Accounts -> Email verification
  4. Create a user.
  5. Click the verification link in the email.

Expected behavior:

Email should be verified

Actual behavior:

Email isn't verified

Relevant logs:

[34mI20180315-11:14:42.564(0) Meteor ➔ publish null -> userId: null , arguments: {} I20180315-11:14:42.570(0) Exception while invoking method 'verifyEmail' MongoError: The positional operator did not find the match needed from the query. Unexpanded update: emails.$.verified at Function.MongoError.create (/home/otm-admin/Rocket.Chat/programs/server/npm/node_modules/meteor/npm-mongo/node_modules/mongodb-core/lib/error.js:31:11) at toError (/home/otm-admin/Rocket.Chat/programs/server/npm/node_modules/meteor/npm-mongo/node_modules/mongodb/lib/utils.js:139:22) at /home/otm-admin/Rocket.Chat/programs/server/npm/node_modules/meteor/npm-mongo/node_modules/mongodb/lib/collection.js:1059:67 at /home/otm-admin/Rocket.Chat/programs/server/npm/node_modules/meteor/npm-mongo/node_modules/mongodb-core/lib/connection/pool.js:469:18 at _combinedTickCallback (internal/process/next_tick.js:131:7) at process._tickDomainCallback (internal/process/next_tick.js:218:9) I20180315-11:14:42.570(0) Meteor ➔ publish roles -> userId: null , arguments: {} I20180315-11:14:42.571(0) Meteor ➔ publish stream-importers -> userId: null , arguments: { '0': 'progress', '1': { useCollection: false, args: [] } } I20180315-11:14:42.572(0) Meteor ➔ publish meteor_autoupdate_clientVersions -> userId: null , arguments: {} I20180315-11:14:42.575(0) Meteor ➔ publish stream-notify-all -> userId: null , arguments: { '0': 'updateCustomSound', '1': { useCollection: false, args: [] } } I20180315-11:14:42.576(0) Meteor ➔ publish stream-notify-all -> userId: null , arguments: { '0': 'deleteCustomSound', '1': { useCollection: false, args: [] } } I20180315-11:14:42.577(0) Meteor ➔ publish activeUsers -> userId: null , arguments: {} I20180315-11:14:42.578(0) Meteor ➔ publish userData -> userId: null , arguments: {} I20180315-11:14:42.579(0) Meteor ➔ publish stream-notify-all -> userId: null , arguments: { '0': 'public-settings-changed', '1': { useCollection: false, args: [] } } I20180315-11:14:42.587(0) Meteor ➔ method autoTranslate.getSupportedLanguages -> userId: null , arguments: { '0': 'en' } I20180315-11:14:42.590(0) Meteor ➔ method listCustomSounds -> userId: null , arguments: {} I20180315-11:14:42.591(0) Meteor ➔ method listEmojiCustom -> userId: null , arguments: {} I20180315-11:14:42.594(0) Meteor ➔ method apps/is-enabled -> userId: null , arguments: {} I20180315-11:14:42.595(0) Meteor ➔ method permissions/get -> userId: null , arguments: {} I20180315-11:14:42.597(0) Meteor ➔ method public-settings/get -> userId: null , arguments: {} I20180315-11:14:42.622(0) Meteor ➔ method UserPresence:online -> userId: null , arguments: { '0': null } I20180315-11:14:42.624(0) Meteor ➔ method loadLocale -> userId: null , arguments: { '0': 'nl' } I20180315-11:14:42.852(0) Meteor ➔ method permissions/get -> userId: null , arguments: { '0': 2018-03-15T11:14:42.650Z } I20180315-11:14:42.973(0) Meteor ➔ method public-settings/get -> userId: null , arguments: { '0': 2018-03-15T11:14:42.818Z }

robindijkhof avatar Mar 15 '18 11:03 robindijkhof

Workaround for now is to fill in the password forgotten form.

robindijkhof avatar Mar 15 '18 11:03 robindijkhof

I just installed Rocket.chat via Docker and got the same issue.

Rocket.Chat Version: 0.62.2
NodeJS Version: 8.9.3 - x64
Platform: linux
Process Port: 3001
ReplicaSet OpLog: Disabled
Commit Hash: 07f0e3f77c
Commit Branch: HEAD     

tranduyhung avatar Mar 16 '18 13:03 tranduyhung

I'm seeing this, too, after upgrading to 0.62.2 from 0.61.4 - note, on mongo pinned to 3.4 because a previous upgrade of all my Docker containers (using docker-compose) that moved mongo beyond 3.4 failed...

lightweight avatar Mar 23 '18 02:03 lightweight

Me to. Rct: 0.62.2 Node: v8.9.3 MongoDB: 3.6

sergeydeg avatar Mar 23 '18 08:03 sergeydeg

Yep, seeing this too.

HammyHavoc avatar Mar 23 '18 14:03 HammyHavoc

me too rocket chat version: 0.62.2

AntMarras avatar Mar 23 '18 17:03 AntMarras

me too Rocket 0.62.2 Node 8.9.3 MongoDB 2.6.12 CentOS 7

PavelZhe avatar Mar 24 '18 18:03 PavelZhe

Hi @robindijkhof, thanks let us know of the problem.

theorenck avatar Mar 26 '18 15:03 theorenck

Anybody still seeing this problem on version 0.63? If so, please share any more relevant logs you may have.

Hudell avatar Apr 11 '18 13:04 Hudell

I have the same issue please let me know what logs you would like to see.

geraldinkorea avatar Apr 12 '18 02:04 geraldinkorea

I have the same issue on v.0.63.1 SMTP is configured and tests email is sent as expected. But I got an error Error trying to send email: Mail command failed by clicking "Resend verification email" in "My Account" tab. There is no warning in "View Logs".

daradurvs avatar Apr 12 '18 06:04 daradurvs

Thank you,

My error logs in send mail are sparse, there is no error.

Cheers,

Gerald

On 04/12/2018 03:47 PM, Vyacheslav Daradur wrote:

I have the same issue on v.0.63.1 SMTP is configured and tests email is sent as expected. But I got an error |Error trying to send email: Mail command failed| by clicking "Resend verification email" in "My Account" tab. There is no warning in "View Logs".

— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/RocketChat/Rocket.Chat/issues/10149#issuecomment-380696611, or mute the thread https://github.com/notifications/unsubscribe-auth/AGBC14UkSo1n5KJj60a6_SrWmJss_ufkks5tnvh1gaJpZM4Sr-PD.

geraldinkorea avatar Apr 12 '18 23:04 geraldinkorea

@Hudell Same issue here on 63.1

If there's further logs you need than what's in the rocket chat main log, let me know and I will get them.

(I just installed. so you'll have to tell me what logs they are because I really dont know my way around this system yet)

hdaws avatar Apr 13 '18 03:04 hdaws

Anybody had this problem with any version prior to 0.62.2?

And do all of you have the setting "Manually Approve New Users" set to true, or it happens with that setting set to false too?

Hudell avatar Apr 24 '18 20:04 Hudell

Email verification works neither with "Manually Approve New Users" nor without that setting. I always get:

Exception while invoking method 'verifyEmail' MongoError: The positional operator did not find the match needed from the query. Unexpanded update: emails.$.verified
    at Function.MongoError.create (/opt/rocketchat-0.64.0-rc1/programs/server/npm/node_modules/meteor/npm-mongo/node_modules/mongodb-core/lib/error.js:31:11)
    at toError (/opt/rocketchat-0.64.0-rc1/programs/server/npm/node_modules/meteor/npm-mongo/node_modules/mongodb/lib/utils.js:139:22)
    at /opt/rocketchat-0.64.0-rc1/programs/server/npm/node_modules/meteor/npm-mongo/node_modules/mongodb/lib/collection.js:1059:67
    at /opt/rocketchat-0.64.0-rc1/programs/server/npm/node_modules/meteor/npm-mongo/node_modules/mongodb-core/lib/connection/pool.js:469:18
    at _combinedTickCallback (internal/process/next_tick.js:131:7)
    at process._tickDomainCallback (internal/process/next_tick.js:218:9)

Exception while invoking method 'verifyEmail' MongoError: The positional operator did not find the match needed from the query. Unexpanded update: emails.$.verified
    at Function.MongoError.create (/opt/rocketchat-0.64.0-rc1/programs/server/npm/node_modules/meteor/npm-mongo/node_modules/mongodb-core/lib/error.js:31:11)
    at toError (/opt/rocketchat-0.64.0-rc1/programs/server/npm/node_modules/meteor/npm-mongo/node_modules/mongodb/lib/utils.js:139:22)
    at /opt/rocketchat-0.64.0-rc1/programs/server/npm/node_modules/meteor/npm-mongo/node_modules/mongodb/lib/collection.js:1059:67
    at /opt/rocketchat-0.64.0-rc1/programs/server/npm/node_modules/meteor/npm-mongo/node_modules/mongodb-core/lib/connection/pool.js:469:18
    at _combinedTickCallback (internal/process/next_tick.js:131:7)
    at process._tickDomainCallback (internal/process/next_tick.js:218:9)

ghost avatar Apr 25 '18 07:04 ghost

On our server new users have been able to verify their emails without issues, but previously we had this issue. Unfortunately I don't know what changed, I just remember being surprised that new users could sign in without me interfering. Version 0.63.0 Mongo 3.4

spaasis avatar Apr 25 '18 08:04 spaasis

Bug still present in 0.64.0-rc3.

ghost avatar Apr 25 '18 09:04 ghost

@Hudell

Have this problem on 0.62.1 "Manually Approve New Users" set to false

aleks-o avatar Apr 25 '18 10:04 aleks-o

Hi, my issue has been resolved after the chat had been updated via Snap to v.0.63.3 "Resend verification email" button in "My Account" tab works well now. Thanks!

daradurvs avatar Apr 25 '18 19:04 daradurvs

Sending the verification mail is not the problem for me. Clicking on the link send by it is.

ghost avatar Apr 26 '18 07:04 ghost