This one is a bit off-topic however I'm hoping that someone has come across something similar and can point me in the right direction.
I would like to try to intercept certain outgoing emails which have an attachment matching a particular set of criteria and then, on-the-fly, rename the attachment (or extract, rename and re-attach it). Maybe via a content filter - amavis or procmail ??? These emails have a MIME "Content-Type: application/pdf;" header but the filename does not have a .pdf extension, which confuses the bulk of Windows email clients. I vaguely remember doing something similar with tnef/winmail.dat files over a decade ago but I can't find any details now (and I may be completely off base). Thanks in advance.