[Looking for Charlie's main web site?]

CF8 Hidden Gem: CFMAIL auto-generated message-id uses specified mail server name

Note: This blog post is from 2007. Some content may be outdated--though not necessarily. Same with links and subsequent comments from myself or others. Corrections are welcome, in the comments. And I may revise the content as necessary.
Here's a neat hidden gem for CF8 that will delight some: CFMAIL now uses the mail server name you specify in CFMAIL SERVER attribute or the CF Admin mail setup page, in creating the message-id header that's generated when your mail is sent.

Some have lamented that in CFMX 6 and 7, it instead used the name of your server where CF is installed, which might be something like "server1" or "bingo", as in:

Message-ID: <23070863.1197039960343.JavaMail.SYSTEM@Server1>

This might cause a recipient mail server to flag the mail as spam, if the mail server was a different domain name (like "yourcompany.com"). The bummer was that many found no way to fix this. Sure, in CF5 you could set it in a CFMAILPARAM to set a mail header, but CF 6 and above ignores that.

So the good news is that CF8 now does use that CF Admin or CFMAIL SERVER value to create the message-id. If I use CFMAIL SERVER="mail.carehart.org"..., for instance, I might get something like:

Message-ID: <[email protected]>

What about CF 6 or 7?

But what if you're on 6 or 7? Well, there's a solution for you, too, by way of a tweak in the CF startup script (jvm.config) or (less preferably) in code. Since the change for CF 6 or 7 deserves some explanation to do it justice, I'll take that up in a part 2 message next. I'll also lay out the whole problem with the auto-generated message-id and why it's a concern for some.

For now, I just wanted to get this word out to those who understand the problem already that CF8 solves it. Woo hoo.

For more content like this from Charlie Arehart: Need more help with problems?
  • If you may prefer direct help, rather than digging around here/elsewhere or via comments, he can help via his online consulting services
  • See that page for more on how he can help a) over the web, safely and securely, b) usually very quickly, c) teaching you along the way, and d) with satisfaction guaranteed
Comments
Good info to have Charlie. I really wanted to see how to fix this on CF7 since that is what I use and do get comments from users about not getting emails, so googled it to find the answer! ;-)
This is a BIGGIE for me! I had been struggling with this since the upgrade to CF8. I even emailed Ben Forta - he didn't know anything about it!
Hope it was helpful, Bob. Mary Jo, sorry I missed your note back in December. Sorry, even more, for failing to offer the part 2 (to cover the CF7 stuff) when I said I'd post it "next". But I have now posted that.

http://carehart.org/...
It was definitely helpful and I can't believe Adobe hasn't trumpeted this one from the rooftops! I had been using the workaround for CF7 that you just blogged about, but when switching to CF8, I had been noticing that it ALWAYS showed an IP address, regardless of other settings.

This seems to be HUGE problem to me, because I had always used the IP address of the mail server that I wanted CF to use through the CF Admin. I had only actually set the SERVER property in CFMAIL a few times, and even then used the IP address.

For someone using servers behind a firewall (which I hope is most people!), you ended up with something like 192.168.1.3 as the portion after the '@', and that seemed to be very quickly picked up as a SPAM-related IP address!

It really is a more significant setting than most people probably realize and I think Adobe should say something about it!
Thanks Charlie, changing the JVM.config was the solution I found but I appreciate the additional information. Glad they readdressed this in CF8 though.
Copyright ©2024 Charlie Arehart
Carehart Logo
BlogCFC was created by Raymond Camden. This blog is running version 5.005.
(Want to validate the html in this page?)

Managed Hosting Services provided by
Managed Dedicated Hosting