Project

General

Profile

Bug #6800

crash on invalid email address

Added by Frédéric Péters almost 5 years ago. Updated almost 5 years ago.

Status:
Fermé
Priority:
Normal
Category:
-
Target version:
Start date:
24 Mar 2015
Due date:
% Done:

100%

Patch proposed:
Yes
Planning:
No

Description

Mimicking #6796, the registration page crashed when I entered an invalid email address (fpeters@0d..be). Do note it is mitigated by the use of type="email" as client-side verification should happen first.

File "/usr/lib/python2.7/dist-packages/authentic2/validators.py" in __call__
  44.         mxs = self.check_mxs(hostname)
File "/usr/lib/python2.7/dist-packages/authentic2/validators.py" in check_mxs
  29.                 socket.gethostbyname(force_text(domain).encode('idna'))
File "/usr/lib/python2.7/encodings/idna.py" in encode
  164.             result.append(ToASCII(label))
File "/usr/lib/python2.7/encodings/idna.py" in ToASCII
  73.         raise UnicodeError("label empty or too long")

0001-validators-verify-that-email-s-domain-idna-encoding-.patch View (3.88 KB) Benjamin Dauvergne, 24 Mar 2015 10:47 AM

Associated revisions

Revision eaa6e23e (diff)
Added by Benjamin Dauvergne almost 5 years ago

validators: verify that email's domain idna encoding succeed before validating it (#6800)

Revision 10e38ad4 (diff)
Added by Benjamin Dauvergne almost 5 years ago

validators: verify that email's domain idna encoding succeed before validating it (#6800)

History

#1 Updated by Benjamin Dauvergne almost 5 years ago

#2 Updated by Frédéric Péters almost 5 years ago

Ack.

#3 Updated by Benjamin Dauvergne almost 5 years ago

  • Target version set to 2.2.0

#4 Updated by Benjamin Dauvergne almost 5 years ago

  • Status changed from Nouveau to Solution déployée

#5 Updated by Benjamin Dauvergne almost 5 years ago

  • Status changed from Solution déployée to Résolu (à déployer)

#6 Updated by Benjamin Dauvergne almost 5 years ago

  • Target version changed from 2.2.0 to 2.1.14

#7 Updated by Benjamin Dauvergne almost 5 years ago

  • % Done changed from 0 to 100

#8 Updated by Benjamin Dauvergne almost 5 years ago

  • Status changed from Résolu (à déployer) to Fermé

Also available in: Atom PDF