[rt-users] Big problem with encoding subject
Albert Shih
Albert.Shih at obspm.fr
Mon Sep 23 17:09:26 EDT 2013
Le 23/09/2013 à 22:30:21+0200, Albert Shih a écrit
> >
>
> Any help ?
>
> I'm totally stuck with this problem. The point is not only because I lost
> some UTF-8 character, but because with some UTF-8 in the subject some scrip
> don't work, the mail isn't send by RT to the requestor (for example).
>
> Today I install from empty disk (on vmware) a fresh FreeBSD 9.2-RC4, I
> don't use anything from the old config, I init a empty database
> (rt-setup-database --action=init). And I still get the problem.
>
> So the problem don't come from error in the configuration.
>
> I remark, with fresh install the « autoreply » scrip (who have in the
> script «Subject : etc..» is working perfectly, but since the « subject » is
> not inside the scrip it's stop working, the encoding is wrong.
>
> Any help would very very welcome.
>
> For example : where the subject is encoded inside RT and with which perl package ?
>
I try to find where the subject is encoded and find this thing little
strange.
I put some RT:Logger inside
Action/SendEmail.pm
in
sub SetHeaderAsEncoding {
my $self = shift;
my ( $field, $enc ) = ( shift, shift );
my $head = $self->TemplateObj->MIMEObj->head;
if ( lc($field) eq 'from' and RT->Config->Get('SMTPFrom') ) {
$head->replace( $field, RT->Config->Get('SMTPFrom') );
return;
}
my $value = $head->get( $field );
$RT::Logger->debug( "In Action/Sendmail.pm '$field' and '$value' before ") ;
$value = $self->MIMEEncodeString( $value, $enc );
$head->replace( $field, $value );
$RT::Logger->debug( "In Action/Sendmail.pm '$value' just after ") ;
}
and the thing is in the log I find
Sep 23 23:05:49 support-9 RT: In Action/Sendmail.pm 'Subject' and '[Support #5] AutoReply: Essai, \xc3\xa9, \xc3\xa0, \xc3\xa3 ' before
Sep 23 23:05:49 support-9 RT: In Action/Sendmail.pm '=?UTF-8?B?W1N1cHBvcnQgIzVdIEF1dG9SZXBseTogRXNzYWksIMOpLCDDoCwgw6M=?=' just after
Sep 23 23:05:49 support-9 RT: Converting 'utf-8' to 'utf-8' for text/plain - =?UTF-8?B?W1N1cHBvcnQgIzVdIEF1dG9SZXBseTogRXNzYWksIMOpLCDDoCwgw6M=?=
Sep 23 23:05:49 support-9 RT: In Action/Sendmail.pm 'Subject' and '[Support #5] Essai, \xef\xbf\xbd, \xef\xbf\xbd, \xef\xbf\xbd ' before
Sep 23 23:05:49 support-9 RT: In Action/Sendmail.pm '=?UTF-8?B?W1N1cHBvcnQgIzVdIEVzc2FpLCDvv70sIO+/vSwg77+9?=' just after
Sep 23 23:05:49 support-9 RT: Converting 'utf-8' to 'utf-8' for text/plain - =?UTF-8?B?W1N1cHBvcnQgIzVdIEVzc2FpLCDvv70sIO+/vSwg77+9?=
the first couple of encoding is correct, but why (normal ? ) RT try to
encode a second time, anyway the second time is wrong.
So or the problem come from RT with two encoding, or he come from some perl
package.
Regards.
JAS
--
Albert SHIH
DIO bâtiment 15
Observatoire de Paris
5 Place Jules Janssen
92195 Meudon Cedex
France
Téléphone : +33 1 45 07 76 26/+33 6 86 69 95 71
xmpp: jas at obspm.fr
Heure local/Local time:
lun 23 sep 2013 23:02:21 CEST
More information about the rt-users
mailing list