View Issue Details

This bug affects 1 person(s).
 10
IDProjectCategoryView StatusLast Update
18257Bug reportsUser / Groups / Rolespublic2023-11-17 15:11
ReporterAdrianR Assigned To 
PrioritynoneSeverityminor 
Status feedbackResolutionopen 
Product Version5.3.x 
Summary18257: Multiple users with same email address
Description

When a new user is added, the same email address as an existing one can be added.

Steps To Reproduce

Steps to reproduce

Create two accounts with different account name but same email address

Expected result

A warning that this email is already in use and stop user creating process (don't run user create php form)

Actual result

Both users are created with the same email address.

TagsNo tags attached.
Bug heat10
Complete LimeSurvey version number (& build)5.3.26+220720
I will donate to the project if issue is resolvedNo
Browser
Database type & versionMySQL 5.7.38
Server OS (if known)CentOS Stream 8
Webserver software & version (if known)Apache 2.4
PHP Version7.4

Relationships

related to 19237 feedbacktibor.pacalat User should not be able to change their email to an existing one 

Users monitoring this issue

There are no users monitoring this issue.

Activities

ollehar

ollehar

2022-07-19 10:35

administrator   ~71007

Should probably have a unique constraint in the database, or at least active record validation rules.

tpartner

tpartner

2022-07-19 11:58

partner   ~71009

Last edited: 2022-07-19 12:00

I'm not sure I see it as a bug. I regularly add test users or add users where I want the password automatically created but not sent to the user by LimeSurvey so I use my email address.

Or maybe just a warning?

ollehar

ollehar

2022-07-19 12:00

administrator   ~71010

It's not about sending out emails, but having the email address being unique for each user.

tpartner

tpartner

2022-07-19 12:01

partner   ~71011

I understand that. I have expanded my comment slightly.

gabrieljenik

gabrieljenik

2022-07-19 20:02

manager   ~71020

I am not sure this is a minor thing, as the "minor" severuty implies. Is it?

AdrianR

AdrianR

2022-07-20 08:40

reporter   ~71036

From all options,, "minor" is the best match for this

gabrieljenik

gabrieljenik

2022-07-21 17:49

manager   ~71087

In which cases this will be an issue?
I believe it is not a bug. Although strange, is not causing troubles, is it?

Right now, LS has lot of installations which could be impacted by a general change we can introduce.
If needed, we could add a setting to "enforce unique emails for accounts".

ollehar

ollehar

2022-07-21 18:34

administrator   ~71088

I guess if you make a typo in an email address, wrong person would get access to wrong data, and there will be no warning.

gabrieljenik

gabrieljenik

2022-07-21 19:02

manager   ~71089

I guess if you make a typo in an email address, wrong person would get access to wrong data, and there will be no warning.

Agree. But is that in relation to this ticket?

ollehar

ollehar

2023-11-14 15:14

administrator   ~78454

Someone reported a security issue related to this.

DenisChenu

DenisChenu

2023-11-14 16:59

developer   ~78458

It's not about sending out emails, but having the email address being unique for each user.

LDAP user didn't need email, WebServer user didn't need email.

I guess if you make a typo in an email address, wrong person would get access to wrong data, and there will be no warning.

And ? Why it's an issue ? With or without unique validation : user can make typo .

Someone reported a security issue related to this.

I like to know the security issue here ?

In my opinion : it's not a bug.

DenisChenu

DenisChenu

2023-11-14 17:14

developer   ~78467

Someone reported a security issue related to this.

Maybe related to allow user to connect via email only in AithLDAP ? In my opinion this must be disable (except with a setting maybe)

gabrieljenik

gabrieljenik

2023-11-14 20:03

manager   ~78481

My 2 cents.

LS doesn't use email as userid.
Now all systems do that.
But LS is kind of old, so LS is username based.

Nowadays, I wouldn't allow 2 users with same email.
Seems strange. Also, everyone expects to be unique now.

So, not a bug. But I would not allow it.

DenisChenu

DenisChenu

2023-11-15 08:50

developer   ~78485

Last edited: 2023-11-15 08:51

So, not a bug. But I would not allow it.

New global setting option ?

And in case of unicity : we must allow empty email (for webserver or LDAP plugin (and all other plugin without email address).

DenisChenu

DenisChenu

2023-11-15 11:27

developer   ~78491

How do you use (and why it exist) Add dummy user

DenisChenu

DenisChenu

2023-11-15 11:27

developer   ~78492

PS : Now all systems do that.

It's false no php forum use email for identity.

gabrieljenik

gabrieljenik

2023-11-15 23:51

manager   ~78493

How do you use (and why it exist) Add dummy user

That's a good question.
Maybe just add random chars before the '@' as to comply.
like gabriel+123456@example.com

New global setting option ?

At PHP config level maybe.
That's not something to change often.

DenisChenu

DenisChenu

2023-11-16 08:43

developer   ~78494

Maybe just add random chars before the '@' as to comply.

Yes : but currently it was created since years with same email …

I know how to create multiple email address with one account (and i ca nuse + or _ personnaly)

At PHP config level maybe.

Yes, for starting, default to false (allow multiple user with same email).

We still need to allow user with empty email.

gabrieljenik

gabrieljenik

2023-11-16 13:11

manager   ~78501

Yes : but currently it was created since years with same email …

Not sure what you mean... Still, things can change, right?

Yes, for starting, default to false (allow multiple user with same email).

I would say the other way around.
For new installations, I wouldn't allow same email.

We still need to allow user with empty email.

If email is unique, means email is considered key.
Why would we allow empty then.?

DenisChenu

DenisChenu

2023-11-17 10:08

developer   ~78506

Not sure what you mean... Still, things can change, right?

Yes: but no issue since years with multiple user with same email address. I still waiting for the potential security issue with this behaviour.

I would say the other way around.

Why i really see NO reason to disallow same email for different user

For new installations, I wouldn't allow same email.

How do you now it's a new installation ?

Why would we allow empty then.?

We don't need email for webserver Auth, LDAP Auth etc … Why force something not necessary ? It's an issue since years … Auth plugin

For webserver : we get it form config.php : https://github.com/LimeSurvey/LimeSurvey/blob/5c210ea28a6d14d6e8442eeef75155ed3bdd742a/application/core/plugins/Authwebserver/Authwebserver.php#L127
I already create a fork of AuthLDAP allowing LDAP without email
Shiboiolet don't force email : https://github.com/atlet/LimeSurvey-ShibbolethAuth/blob/174a2234a82586169869d4987e467b6f2ce6b00a/ShibbolethAuth.php#L96
etc …

If you force unicity on email and disallow empty email : you broke 3 plugins … without an option to fix it …

ollehar

ollehar

2023-11-17 11:56

administrator   ~78508

See https://bugs.limesurvey.org/view.php?id=19237

ollehar

ollehar

2023-11-17 12:05

administrator   ~78509

What about unique constraint but allow empty email?

DenisChenu

DenisChenu

2023-11-17 15:05

developer   ~78511

See https://bugs.limesurvey.org/view.php?id=19237

Already answered :
https://bugs.limesurvey.org/view.php?id=19237#c78461

What about unique constraint but allow empty email?

Already answered :
https://bugs.limesurvey.org/view.php?id=18257#c78485

gabrieljenik

gabrieljenik

2023-11-17 15:11

manager   ~78512

Why i really see NO reason to disallow same email for different user

It is not what the usual people expect today.

We don't need email for webserver Auth, LDAP Auth etc … Why force something not necessary ? It's an issue since years … Auth plugin

I haven't gone that dip. Still, I was picturing to be handled outside of the auth plugins.
Just like any other extra piece of data, as it would be a phone number.
Not sure that's possible though.

What about unique constraint but allow empty email?

Could be good

Issue History

Date Modified Username Field Change
2022-07-19 09:20 AdrianR New Issue
2022-07-19 10:35 ollehar Note Added: 71007
2022-07-19 10:35 ollehar Bug heat 0 => 2
2022-07-19 11:58 tpartner Note Added: 71009
2022-07-19 11:58 tpartner Bug heat 2 => 4
2022-07-19 11:59 tpartner Note Edited: 71009
2022-07-19 12:00 tpartner Note Edited: 71009
2022-07-19 12:00 ollehar Note Added: 71010
2022-07-19 12:01 tpartner Note Added: 71011
2022-07-19 20:02 gabrieljenik Note Added: 71020
2022-07-19 20:02 gabrieljenik Bug heat 4 => 6
2022-07-20 08:40 AdrianR Note Added: 71036
2022-07-20 08:40 AdrianR Bug heat 6 => 8
2022-07-21 17:49 gabrieljenik Note Added: 71087
2022-07-21 17:49 gabrieljenik Status new => feedback
2022-07-21 18:34 ollehar Note Added: 71088
2022-07-21 19:02 gabrieljenik Note Added: 71089
2023-11-14 15:14 ollehar Note Added: 78454
2023-11-14 16:59 DenisChenu Note Added: 78458
2023-11-14 16:59 DenisChenu Bug heat 8 => 10
2023-11-14 17:14 DenisChenu Note Added: 78467
2023-11-14 20:03 gabrieljenik Note Added: 78481
2023-11-15 08:50 DenisChenu Note Added: 78485
2023-11-15 08:51 DenisChenu Note Edited: 78485
2023-11-15 11:27 DenisChenu Note Added: 78491
2023-11-15 11:27 DenisChenu File Added: Capture d’écran du 2023-11-15 11-26-22.png
2023-11-15 11:27 DenisChenu Note Added: 78492
2023-11-15 16:32 DenisChenu Relationship added related to 19237
2023-11-15 23:51 gabrieljenik Note Added: 78493
2023-11-16 08:43 DenisChenu Note Added: 78494
2023-11-16 13:11 gabrieljenik Note Added: 78501
2023-11-17 10:08 DenisChenu Note Added: 78506
2023-11-17 11:56 ollehar Note Added: 78508
2023-11-17 12:05 ollehar Note Added: 78509
2023-11-17 15:05 DenisChenu Note Added: 78511
2023-11-17 15:11 gabrieljenik Note Added: 78512