Lucee 5.2.9.31 unable to CFMAIL to an address with an underscore character

Description

Any idea how to CFMAIL an address with an underscore? Running this code errors with "One of the following attribtues must be defined". It works in ACF8, but not in Lucee 5.2. I tried escaping the underscore with a \, tried the %5 instead... no luck.

Also interesting that Lucee spelled "attributes" incorrectly.

<cfmail to="you@your_family.com" from="me@me.com" subject="Test" type="HTML"> <html><body>Test.</body></html> </cfmail>

This is where the error comes from https://github.com/lucee/Lucee/blob/5479f06cc8e3ebe567d9e92aa74c5b324f8b5cb5/core/src/main/java/lucee/runtime/tag/Mail.java#L526

Environment

Linux 4.9.125-linuxkit

relates to

Activity

Pothys - MitrahSoft 
12 February 2019 at 13:31

Hi ,

I checked this ticket with lucee 5.2 & 5.3 latest and also in ACF 10,11,16 . All of them doesn't support '_' with an email address. ACF 9 works fine & it supports as like as you mentioned above. So please check it.

The main reason i think is,
To promote interoperability and consistent with long-standing guidance about conservative use of the DNS in naming and applications, characters outside the set of alphabetic characters, digits, and hyphen MUST NOT appear in domain name labels for SMTP clients or servers. In particular, the underscore character is not permitted.

Please check here for more details.
https://social.technet.microsoft.com/Forums/ie/en-US/69f393aa-d555-4f8f-bb16-c636a129fc25/what-are-valid-and-invalid-email-address-characters?forum=exchangesvradminlegacy

Due to this reason, ACF also rejected these kind of email addresses from ACF 10 itself
I've added a fix to correct the word 'attributes'

Pull request: https://github.com/lucee/Lucee/pull/629

Won't Do

Details

Assignee

Reporter

Priority

Labels

New Issue warning screen

Before you create a new Issue, please post to the mailing list first https://dev.lucee.org

Once the issue has been verified, one of the Lucee team will ask you to file an issue

Affects versions

Created 6 February 2019 at 21:33
Updated 14 May 2020 at 08:34
Resolved 8 April 2019 at 19:10