[ic] [interchange-core] Encoding of mail headers

Mike Heins mike at perusion.com
Wed Mar 4 16:27:57 UTC 2009


Quoting David Christensen (david at endpoint.com):
> 
> On Mar 4, 2009, at 9:27 AM, Stefan Hornburg wrote:
> 
> > David Christensen wrote:
> >> On Mar 4, 2009, at 2:52 AM, Stefan Hornburg (Racke) wrote:
> >>
> >>> According to RFC 2047 mail headers with characters other than US-
> >>> ASCII needs
> >>> to be escaped. Interchange fails to do so, resulting in emails
> >>> delivered
> >>> which will be tagged by Spamassassin with SUBJECT_NEEDS_ENCODING and
> >>> SUBJ_ILLEGAL_CHARS.
> >>>
> >>> I wrote a simple filter which addresses this problem:
> >>>
> >>> CodeDef mime_encode_words Filter
> >>> CodeDef mime_encode_words Description Find MIME type of filename
> >>> CodeDef mime_encode_words Routine <<EOR
> >>>
> >>> use MIME::EncWords;
> >>>
> >>> sub {
> >>> 	return MIME::EncWords::encode_mimewords(shift);
> >>> }
> >>> EOR
> >>>
> >>> Of course the whole IC email infrastructure needs to be adjusted to
> >>> use
> >>> this.
> >>
> >> The Encode module also offers this capability, and has the benefit of
> >> being core.  While we're doing this, we should revisit the body
> >> encoding as well.  I definitely agree that this should be done.
> >>
> >
> > How would this work with Encode?
> >
> > Regards
> > 	Racke
> 
> 
> use Encode qw(encode);
> 
> sub mime_encode_header {
>      return encode('MIME-Header',shift);
> }
> 

Why would we prefer the Encode module, which has known problems
with Safe?

-- 
Mike Heins
Perusion -- Expert Interchange Consulting    http://www.perusion.com/
phone +1.765.328.4479  <mike at perusion.com>

Research is what I'm doing when I don't know what I'm doing.
-- Wernher Von Braun



More information about the interchange-users mailing list