#121 Wrong utf-8 decoding in message headers

closed-fixed
nobody
None
5
2005-11-06
2005-07-27
Anonymous
No

When you send a message with russian characters in
Subject field from SquirrelMail Web-interface, they are
automatically encoded as utf-8 (by encoding each
character's hexadecimal value), for example:

Subject:
=?utf-8?Q?
=D0=92=D0=BE=D1=81=D1=81=D1=82=D0=B0=D0=B
D=D0=BE=D0=B2=D0=BB?=
=?utf-8?Q?
=D0=B5=D0=BD_=D1=84=D1=82=D0=BF_=D1=81=D0=
B5=D1=80=D0=B2=D0?=
=?utf-8?Q?=B5=D1=80?=

As you see, there are 3 encoding words, and between
the 2nd and the 3rd ones high and low bytes of a single
utf-8 character (hex:D0B5) are splitted.
When this message is received by SquirrelMail Web-
interface (i.e. you send message back to yourself), web-
interface decodes this character as double question mark
(??) instead of decoding real russian character.

SquirrelMail version 1.4.4-rc1

Discussion

  • Tomas Kuliavas

    Tomas Kuliavas - 2005-07-29

    Logged In: YES
    user_id=225877

    I suspect that issue is related to [870359] 'encodeHeader
    does not work correctly with long headers'.

    utf8-wrapping-and-encoding.diff is made for 1.4.5.

     
  • Tomas Kuliavas

    Tomas Kuliavas - 2005-08-02

    Logged In: YES
    user_id=225877

    sorry, patch is unstable and needs more testing.

     
  • Tomas Kuliavas

    Tomas Kuliavas - 2005-08-04

    Logged In: YES
    user_id=225877

    1.5.1cvs uses B encoding instead of Q encoding with utf-8,
    big5, gb2312 and euc-kr character sets. Issue is specific to
    stable. Fix is in encodeHeader() and encodeHeaderBase64()
    functions.

     
  • Tomas Kuliavas

    Tomas Kuliavas - 2005-08-04
    • labels: 102906 -->
     
  • Tomas Kuliavas

    Tomas Kuliavas - 2005-11-06

    Logged In: YES
    user_id=225877

    fixed in 1.4.6cvs. Fix requires php with mbstring support.

     
  • Tomas Kuliavas

    Tomas Kuliavas - 2005-11-06
    • status: open --> closed-fixed
     

Get latest updates about Open Source Projects, Conferences and News.

Sign up for the SourceForge newsletter:





No, thanks