Mail filename of attachment show incorrectly

When use Q-encoded to handle non-ASCII characters, if raw characters start with non-ASCII, we will get encoded like '=?UTF-8?Q?=XX=XX?='. IOS(>26) Mail App may think the first '?=' end of the '=?UTF-8?Q?=' is then end flag, so show incorrectly.

Answered by DTS Engineer in 886227022

I send mail by smtp protocol and javamail api.

Ah, OK. So your issue is that the Mail app’s MIME support doesn’t match your expectations.

Given that this doesn’t involve any Apple APIs — it’s about the behaviour of the Mail app itself — this isn’t really something we can help you with here on the forums. Our focus is on Apple APIs, Apple developer tools, and so on.

So, my advice is that you file a bug about this, explaining what you’re doing and why you think the Mail app is handling this incorrectly. Make sure to include screenshots of the problem. And, if you can reproduce this on the Mac, it’d be helpful to include a copy of the message as a .eml file. In Mail, get this by choosing Message > Forward as Attachment.

Also, if your messages render correctly on other common platforms, I recommend that you include those details, and screenshots from them as well.

Share and Enjoy

Quinn “The Eskimo!” @ Developer Technical Support @ Apple
let myEmail = "eskimo" + "1" + "@" + "apple.com"

Are you interacting with Mail via some API? Or are you hitting this while working with the Mail app as a normal user might?

Share and Enjoy

Quinn “The Eskimo!” @ Developer Technical Support @ Apple
let myEmail = "eskimo" + "1" + "@" + "apple.com"

I send mail by smtp protocol and javamail api.

Ah, OK. So your issue is that the Mail app’s MIME support doesn’t match your expectations.

Given that this doesn’t involve any Apple APIs — it’s about the behaviour of the Mail app itself — this isn’t really something we can help you with here on the forums. Our focus is on Apple APIs, Apple developer tools, and so on.

So, my advice is that you file a bug about this, explaining what you’re doing and why you think the Mail app is handling this incorrectly. Make sure to include screenshots of the problem. And, if you can reproduce this on the Mac, it’d be helpful to include a copy of the message as a .eml file. In Mail, get this by choosing Message > Forward as Attachment.

Also, if your messages render correctly on other common platforms, I recommend that you include those details, and screenshots from them as well.

Share and Enjoy

Quinn “The Eskimo!” @ Developer Technical Support @ Apple
let myEmail = "eskimo" + "1" + "@" + "apple.com"

Mail filename of attachment show incorrectly
 
 
Q