Opened 12 years ago

Closed 12 years ago

#242 closed task (fixed)

Identifying reporter sometime fails with bi-case email addresses

Reported by: dmcr@… Owned by: bas
Priority: minor Milestone:
Component: email2trac Version: trunk
Keywords: Cc:


Hi Bas,

I had a reporter who updated a ticket he had created; and since email2trac did not recognize him as the reporter, it started a new ticket (while using ticket_permission_system = update_restricted_to_participants).

It turned out to be due to the reporter sometimes using a bi-case email address, and email2trac not always using the lower() method to standardize the addresses.

The attached patch fixes this case, and other similar ones.

Best regards,

Dennis McRitchie?

Attachments (1)

email2trac-2.0.2.patch3 (1.3 KB) - added by dmcr@… 12 years ago.
Lower-case all email addresses before comparing.

Download all attachments as: .zip

Change History (11)

Changed 12 years ago by dmcr@…

Lower-case all email addresses before comparing.

comment:1 Changed 12 years ago by bas

  • Status changed from new to assigned
  • Version changed from 2.0.2 to trunk

Thanks will be applied

comment:2 Changed 12 years ago by bas

  • Milestone set to New email2trac release 2.X.X

comment:3 Changed 12 years ago by bas

  • Resolution set to fixed
  • Status changed from assigned to closed

(In [518]) Fixed comparison of email addresses and author names. Always do lower case comparison, closes #242

comment:4 Changed 12 years ago by anonymous

fwiw, this should be an option, since it breaks RFC compliance for email.

'Fred@…' and 'fred@…' are allowed to be 2 different email addresses. (The original code only lowercases the hostname, which is explicitly not case sensitive in the RFCs: 'fred@…' and 'fred@…' ARE the same email address.)

Note: I'm not saying this new behavior shouldn't be the default, just that it'd be nice to be able to restore RFC compliance.

comment:5 Changed 12 years ago by dmcr@…

It's a good point. However, the RFC states that "exploiting the case sensitivity of mailbox local-parts impedes interoperability and is discouraged". It also states: "While the above definition for Local-part is relatively permissive, for maximum interoperability, a host that expects to receive mail SHOULD avoid defining mailboxes where the Local-part requires (or uses) the Quoted-string form or where the Local-part is case-sensitive."

In this case, the "host that expects to receive mail" is the email2trac server itself, and bas might simply document that the email2trac server defines the local part as case-insensitive (as do most mail servers).


comment:6 Changed 12 years ago by bas

  • Milestone New email2trac release 2.X.X deleted
  • Resolution fixed deleted
  • Status changed from closed to reopened
  • Type changed from defect to enhancement

Thanks for all the info. Did not know that mail addresses could be case sensitive. I could make an option for it. But who uses case sensitive mail addresses?

comment:7 Changed 12 years ago by bas

  • Priority changed from major to minor

comment:8 Changed 12 years ago by dmcr@…

No internet mail provider that I know of uses a case-sensitive local-part for their email addresses. It is simply impractical. It's a wonder to me that this concept was left in the RFC, but if anyone uses this "feature", it must be in intra-net applications. Since email2trac is used in internet applications, I would recommend that you simply, clearly document that, like other internet mail providers, the email2trac server does not support case-sensitive email addresses. If someone needs the case-sensitivity, you could then add an option to provide it.


P.S. BTW, I don't think the way email2trac was coded before my patch fully supported the RFC either. The support for case-sensitivity was inconsistent as I recall.

comment:9 Changed 12 years ago by bas

  • Type changed from enhancement to task

I will document it and it is true and never supported this RFC ;-)

comment:10 Changed 12 years ago by bas

  • Resolution set to fixed
  • Status changed from reopened to closed

Add Comment

Modify Ticket

Change Properties
as closed The owner will remain bas.
The resolution will be deleted. Next status will be 'reopened'.

E-mail address and user name can be saved in the Preferences.

Note: See TracTickets for help on using tickets.