The "local part" of the email address is the username. But I know not all
websites who use Django provide email services. Probably most of them don't.
אורי
u...@speedy.net


On Sat, Jan 5, 2019 at 11:57 PM Nicolas Le Manchet <nico...@lemanchet.fr>
wrote:

> As Kye Russell mentioned, email addresses being case-sensitive for the
> local part and case-insensitive for the domain part is a whole different
> problem that has implications way beyond Django. In my opinion, it is best
> to leave it out of the issue and focus the discussion on usernames.
>
> On Sat, Jan 5, 2019, at 22:43, אורי wrote:
> > I use Google as my email provider. Is it possible to define with Google
> > case-sensitive email addresses? For example, can I define a mailbox "
> > u...@speedy.net" which is different than my mailbox (u...@speedy.net) and
> > belongs to a different user? I don't think so. And remember, if a user is
> > registered with an email address such as webmat...@speedy.net, and then
> > they register again with an email address webmat...@speedy.net, I think
> in
> > most cases you don't want to treat it as a new email address. Especially
> > since it may happen many times by mistake (for example a user may
> register
> > and then forget his password, and try to reset his password with another
> > case email address - for example register with webmat...@speedy.net and
> > reset his password with webmat...@speedy.net). I think if Google ignores
> > this RFC, then probably Speedy Net can ignore this RFC and it's up to
> > Django to decide what to do with this RFC.
> >
> > By the way, my name in Hebrew is אורי and there is no such problem in
> > Hebrew - there are no uppercase or lowercase letters. But I'm not sure
> if I
> > would be able to have an email address with Hebrew letters and receive
> > email from anyone. I don't know anyone who's email address contains a
> > Hebrew letter. I checked now with Chrome and the username part of the
> email
> > (the local part) can't contain Hebrew letters but the domain part can.
> So I
> > can register (to Speedy Net, under development) with an email address
> such
> > as uri@ספידי.נט (but not אורי@speedy.net) and it will be converted to
> > something like "u...@xn--7dblb3ap.xn--debp". If I try to register with
> אורי@
> > speedy.net I receive an error message from Chrome (and I didn't check
> other
> > browsers).
> >
> > "Users who register on mobile don't notice that their phone has
> > automatically capitalised the first letter of their username when they
> > enter it..." - I think a website can disable this feature of capitalizing
> > the first letter in a form, for example in the email address or username
> > field. For example, in Speedy Net we use 'autocomplete="off"
> > autocorrect="off" autocapitalize="off" spellcheck="false"' in the HTML to
> > disable these features.
> >
> > אורי (Uri)
> > u...@speedy.net
> >
> >
> > On Sat, Jan 5, 2019 at 6:10 PM Nasir Hussain <nasirhja...@gmail.com>
> wrote:
> >
> > > What the Standard Says
> > >
> > > RFC 5321 <https://tools.ietf.org/rfc/rfc5321.txt>, the standard that
> > > defines how email transport works, lays down the email address case
> > > sensitivity issue thus:
> > >
> > > The local-part of a mailbox MUST BE treated as case sensitive.
> Therefore, SMTP implementations MUST take care to preserve the case of
> mailbox local-parts. In particular, for some hosts, the user "smith" is
> different from the user "Smith". However, exploiting the case sensitivity
> of mailbox local-parts impedes interoperability and is discouraged. Mailbox
> domains follow normal DNS rules and are hence not case sensitive.
> > >
> > >
> > > On Sat, Jan 5, 2019 at 7:21 PM Kye Russell <m...@kye.id.au> wrote:
> > >
> > >> Involving email addresses in the discussion complicates things
> because of
> > >> the involvement of the email RFC (or RFCs?) which IIRC dictates that
> the
> > >> mailbox portion of an email address may be case sensitive.
> > >>
> > >> Back to OPs point, I feel that you should respect the case of a
> username
> > >> for display purposes. I’d merely do a case insensitive / normalisation
> > >> check for operations like login and conflict checking on signup /
> username
> > >> change. As far as email addresses are concerned, this is even more
> > >> justifiable as you could be dealing with a case sensitive email
> server. No
> > >> idea how common that is these days.
> > >>
> > >> On Sat, 5 Jan 2019 at 10:12 pm, אורי <u...@speedy.net> wrote:
> > >>
> > >>> In Speedy Net all usernames and slugs must be lowercase. If they are
> > >>> entered not lowercase they are converted to lowercase. I don't see
> any
> > >>> reason why usernames should not be lowercase, especially if there
> are 2
> > >>> different users with usernames which differ only in case.
> > >>>
> > >>> All email addresses in Speedy Net are also converted to lowercase and
> > >>> saved lowercase in the database. I think it would be absurd if
> > >>> u...@speedy.net, u...@speedy.net and u...@speedy.net would belong to 3
> > >>> different people with 3 different usernames and email addresses.
> > >>>
> > >>> From
> > >>>
> https://github.com/speedy-net/speedy-net/blob/uri_merge_with_master_2018-12-31_a/speedy/core/accounts/tests/test_forms.py
> > >>> :
> > >>>
> > >>>     def test_slug_gets_converted_to_lowercase(self):
> > >>>         data = self.data.copy()
> > >>>         data['slug'] = 'THIS-IS-A-SLUG'
> > >>>         form = RegistrationForm(language_code=self.language_code,
> > >>> data=data)
> > >>>         form.full_clean()
> > >>>         self.assertTrue(expr=form.is_valid())
> > >>>         self.assertDictEqual(d1=form.errors, d2={})
> > >>>         user = form.save()
> > >>>         self.assertEqual(first=user.slug, second='this-is-a-slug')
> > >>>         self.assertEqual(first=user.username, second='thisisaslug')
> > >>>
> > >>>     def test_email_gets_converted_to_lowercase(self):
> > >>>         data = self.data.copy()
> > >>>         data['email'] = 'emai...@example.com'
> > >>>         form = RegistrationForm(language_code=self.language_code,
> > >>> data=data)
> > >>>         form.full_clean()
> > >>>         self.assertTrue(expr=form.is_valid())
> > >>>         self.assertDictEqual(d1=form.errors, d2={})
> > >>>         user = form.save()
> > >>>         email_addresses = UserEmailAddress.objects.filter(user=user)
> > >>>         email_addresses_set = {e.email for e in email_addresses}
> > >>>         self.assertSetEqual(set1=email_addresses_set, set2={'
> > >>> emai...@example.com'})
> > >>>
> > >>>
> > >>>
> > >>> אורי (Uri)
> > >>> u...@speedy.net
> > >>>
> > >>>
> > >>> On Sat, Jan 5, 2019 at 3:18 PM Shelagh Lewins <
> shelagh.lew...@gmail.com>
> > >>> wrote:
> > >>>
> > >>>> I think case-insensitive usernames is a must-have in the mobile
> world.
> > >>>> Users who register on mobile don't notice that their phone has
> > >>>> automatically capitalised the first letter of their username when
> they
> > >>>> enter it, and are then unable to log in on laptops because they are
> typing
> > >>>> the lower-case version.
> > >>>>
> > >>>> And because case-sensitive usernames are so unexpected, developers
> are
> > >>>> likely not to notice the problem until some way into the project.
> > >>>>
> > >>>> To expect every developer to modify the auth model because it
> doesn't
> > >>>> provide standard functionality seems like the wrong approach to me.
> > >>>>
> > >>>> If there are concerns about backwards compatibility, why not make
> it an
> > >>>> optional setting?
> > >>>>
> > >>>> --
> > >>>> You received this message because you are subscribed to the Google
> > >>>> Groups "Django developers (Contributions to Django itself)" group.
> > >>>> To unsubscribe from this group and stop receiving emails from it,
> send
> > >>>> an email to django-developers+unsubscr...@googlegroups.com.
> > >>>> To post to this group, send email to
> django-developers@googlegroups.com
> > >>>> .
> > >>>> Visit this group at
> https://groups.google.com/group/django-developers.
> > >>>> To view this discussion on the web visit
> > >>>>
> https://groups.google.com/d/msgid/django-developers/3b6d56fd-2664-4b56-8712-e76d51c73172%40googlegroups.com
> > >>>> <
> https://groups.google.com/d/msgid/django-developers/3b6d56fd-2664-4b56-8712-e76d51c73172%40googlegroups.com?utm_medium=email&utm_source=footer
> >
> > >>>> .
> > >>>> For more options, visit https://groups.google.com/d/optout.
> > >>>>
> > >>> --
> > >>> You received this message because you are subscribed to the Google
> > >>> Groups "Django developers (Contributions to Django itself)" group.
> > >>> To unsubscribe from this group and stop receiving emails from it,
> send
> > >>> an email to django-developers+unsubscr...@googlegroups.com.
> > >>> To post to this group, send email to
> django-developers@googlegroups.com.
> > >>> Visit this group at
> https://groups.google.com/group/django-developers.
> > >>> To view this discussion on the web visit
> > >>>
> https://groups.google.com/d/msgid/django-developers/CABD5YeFm3A2k7V8zeRPBxyu8zMv7msnmU1ogS_SrCJT76H_Fzw%40mail.gmail.com
> > >>> <
> https://groups.google.com/d/msgid/django-developers/CABD5YeFm3A2k7V8zeRPBxyu8zMv7msnmU1ogS_SrCJT76H_Fzw%40mail.gmail.com?utm_medium=email&utm_source=footer
> >
> > >>> .
> > >>> For more options, visit https://groups.google.com/d/optout.
> > >>>
> > >> --
> > >> You received this message because you are subscribed to the Google
> Groups
> > >> "Django developers (Contributions to Django itself)" group.
> > >> To unsubscribe from this group and stop receiving emails from it,
> send an
> > >> email to django-developers+unsubscr...@googlegroups.com.
> > >> To post to this group, send email to
> django-developers@googlegroups.com.
> > >> Visit this group at https://groups.google.com/group/django-developers
> .
> > >> To view this discussion on the web visit
> > >>
> https://groups.google.com/d/msgid/django-developers/CANK-ykkFovkYbB921%2BH5yejZFv6CehLnzmQcqZ4EPKr7WRUjww%40mail.gmail.com
> > >> <
> https://groups.google.com/d/msgid/django-developers/CANK-ykkFovkYbB921%2BH5yejZFv6CehLnzmQcqZ4EPKr7WRUjww%40mail.gmail.com?utm_medium=email&utm_source=footer
> >
> > >> .
> > >> For more options, visit https://groups.google.com/d/optout.
> > >>
> > > --
> > > You received this message because you are subscribed to the Google
> Groups
> > > "Django developers (Contributions to Django itself)" group.
> > > To unsubscribe from this group and stop receiving emails from it, send
> an
> > > email to django-developers+unsubscr...@googlegroups.com.
> > > To post to this group, send email to
> django-developers@googlegroups.com.
> > > Visit this group at https://groups.google.com/group/django-developers.
> > > To view this discussion on the web visit
> > >
> https://groups.google.com/d/msgid/django-developers/CAB5Hk3zUYmYy9BFkFJcb9qWiumEXhY1TiqQQGQn5JS2SPqizJA%40mail.gmail.com
> > > <
> https://groups.google.com/d/msgid/django-developers/CAB5Hk3zUYmYy9BFkFJcb9qWiumEXhY1TiqQQGQn5JS2SPqizJA%40mail.gmail.com?utm_medium=email&utm_source=footer
> >
> > > .
> > > For more options, visit https://groups.google.com/d/optout.
> > >
> >
> > --
> > You received this message because you are subscribed to the Google
> > Groups "Django developers  (Contributions to Django itself)" group.
> > To unsubscribe from this group and stop receiving emails from it, send
> > an email to django-developers+unsubscr...@googlegroups.com.
> > To post to this group, send email to django-developers@googlegroups.com.
> > Visit this group at https://groups.google.com/group/django-developers.
> > To view this discussion on the web visit
> >
> https://groups.google.com/d/msgid/django-developers/CABD5YeFwXOFOUgBFBWMyphJDvf45QmFc3K3CER4u7_2Q_i_fsg%40mail.gmail.com
> .
> > For more options, visit https://groups.google.com/d/optout.
>
>
> --
> Nicolas Le Manchet
>
> --
> You received this message because you are subscribed to the Google Groups
> "Django developers  (Contributions to Django itself)" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to django-developers+unsubscr...@googlegroups.com.
> To post to this group, send email to django-developers@googlegroups.com.
> Visit this group at https://groups.google.com/group/django-developers.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/django-developers/1546725419.1509232.1626493552.759DCF29%40webmail.messagingengine.com
> .
> For more options, visit https://groups.google.com/d/optout.
>

-- 
You received this message because you are subscribed to the Google Groups 
"Django developers  (Contributions to Django itself)" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-developers+unsubscr...@googlegroups.com.
To post to this group, send email to django-developers@googlegroups.com.
Visit this group at https://groups.google.com/group/django-developers.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-developers/CABD5YeHN%2B%2Bb7uWvvQ9_imEPz5GCEG%3DTYPzcrbYWb86RzajNHCg%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to