Your achievements

Level 1

0% to

Level 2

Tip /
Sign in

Sign in to Community

to gain points, level up, and earn exciting badges like the new
BedrockMission!

Learn More

View all

Sign in to view all badges

Special characters in emails

Avatar

Avatar
Level 1
oleksiic5434763
Level 1

Likes

0 likes

Total Posts

1 post

Correct Reply

0 solutions
View profile

Avatar
Level 1
oleksiic5434763
Level 1

Likes

0 likes

Total Posts

1 post

Correct Reply

0 solutions
View profile
oleksiic5434763
Level 1

17-07-2019

Hi guys! I faced with the issue related to the sending emails from AEM 6.2 to the email addresses which contain special characters. Example (passed as image, because editor is not correctly convert it):

1793360_pastedImage_1.png

Sending is failing with such message:

javax.mail.internet.AddressException: Local address contains control or whitespace in string bob.o’brien@example.com

After the brief check I found, that default AEM Mail Service (com.day.cq.mailer.DefaultMailService) and its bundle (com.day.cq.cq-mailer) are using libraries org.apache.commons.mail,version=1.5.0 and javax.mail.internet,version=1.5.0. InternetAddress class is not allow non-ASCII characters in local parts. Checked on AEM 6.4, the same versions are used in it.

In the same time I see that Java mail 1.6 supports internationalized (with non-ASCII characters) email (see https://stackoverflow.com/a/42645751 ).

So, my question do anyone faced with similar issue and how do you handle them? Because for me it looks like AEM doesn't support internationalized email addresses at all.

bob.o’brien@example.com

Accepted Solutions (0)

Answers (0)