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

Incorrect Email Validation on various pages

Open smritidoneria opened this issue 1 year ago • 4 comments

Search before asking

  • [X] I had searched in the issues and found no similar issues.

Operating System

  • [X] macOS
  • [ ] Windows
  • [ ] Linux

Operating System Version

MacOs

It happens on the web browser too?

Yes, it happens on the web browser too

Rocket.Chat Desktop App Version

4.1.0

Rocket.Chat Server Version

6.12.1

Describe the bug

Email Validation occur at various places.

  1. while registering , the email has incorrect validation.
  2. While exporting messages

Exporting Messages-

https://github.com/user-attachments/assets/ffc0b646-7b97-4a50-b42d-30ec1a9c359a

While registering-

https://github.com/user-attachments/assets/6a1b99c7-81e0-4123-b4ab-dd189d8d871f

How to Reproduce

While registering- Register yourself without the domain. The interface will lead to another page without showing any error.

Export message- Click on export messages Input the wrong email click send

Describe your Expected behavior

There should be proper email validation, not allowing user to login and export messages without the proper domain.

Anything else

This problem occurs everytime.

Are you willing to submit a code contribution?

  • [X] Yes, I am willing to submit a Pull Request!

smritidoneria avatar Sep 14 '24 11:09 smritidoneria

I'm willing to work on this, if this bug is accepted @jeanfbrito 🚀

smritidoneria avatar Sep 14 '24 11:09 smritidoneria

@jeanfbrito I was exploring the Rocket.chat and I noticed that this issue is an valid issue, so raised the PR for this please check this https://github.com/RocketChat/Rocket.Chat/pull/33398

Tanu1201 avatar Sep 29 '24 10:09 Tanu1201

jeanfbrito I was exploring the Rocket.chat and I noticed that this issue is an valid issue, so raised the PR for this please check this

You don't need to @ anyone - those who need to know will see.

You should check that a fix is required before starting work.

I think this is likely related to this and should be closed as not a bug:

https://github.com/RocketChat/Rocket.Chat/issues/32974#issuecomment-2382605184

As per the comment here

https://github.com/RocketChat/Rocket.Chat/issues/32974#issuecomment-2369375668

Dotless or no TLD emails are valid emails according to the most recent RFC regarding emails (RFC 5322), this is not a bug.

And here:

https://github.com/RocketChat/Rocket.Chat/pull/33012#discussion_r1773484524

Top-level domains (.com, .org, etc) are not mandatory for an email to be considered valid, there is no need to change this regex as this was a purposeful decision on email validation done by our engineering team.

Although it seems a bit incongruous, user@domain is valid according to RFC 5322 and therefore this is not a bug and should be closed.

reetp avatar Sep 30 '24 09:09 reetp

This issue has been marked as stale because there has been no further activity in the last 10 days. If the issue remains stale for the next 4 days (a total of 14 days with no activity), then it will be assumed that the question has been resolved and the issue will be automatically closed.

github-actions[bot] avatar Oct 14 '24 12:10 github-actions[bot]

This issue was closed because it has been inactive for 14 days since being marked as stale.

github-actions[bot] avatar Oct 28 '24 18:10 github-actions[bot]