Gnus development mailing list
 help / color / mirror / Atom feed
* long encoded filename in mime part is truncated and not decoded
@ 2007-06-12  2:29 NAKAJI Hiroyuki
  2007-06-12  4:27 ` Katsumi Yamaoka
  0 siblings, 1 reply; 5+ messages in thread
From: NAKAJI Hiroyuki @ 2007-06-12  2:29 UTC (permalink / raw)
  To: ding

Hi,

Japanese people love to name files using Japanese characters and the
filename is usually looooooooooooooooooooooooooooooooooooooong. And when
a user attached this long-named file, some mail clients truncates the
excoded filename.

For example, when user uses

User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.0; ja-JP; rv:1.4) Gecko/20030624 Netscape/7.1 (ax)

and such a long-named file is attached as mime-multipart, in article
buffer it is shown like this:

[3. application/msword; 44新規学習ニーズ対応プログラム支援経費=?ISO-2022-JP?B?WxskQjpOQnJAKRsoQl0bJEIhS]...

and then, when I typed 'o' at this part, the file is saved as
44新規学習ニーズ対応プログラム支援経費=?ISO-2022-JP?B?WxskQjpOQnJAKRsoQl0bJEIhS 

I don't like it. I want the file to be saved as
44新規学習ニーズ対応プログラム支援経費[採択制]

Is it possible to decode this kind of truncated loooong filename in
Gnus? I got "44新規学習ニーズ対応プログラム支援経費[採択制]" with adding
"=?=" after "...EIhS".

Of cource, I don't mind adding ".doc" after "...[採択制]" by hand when I
save this part.

Regards,
-- 
NAKAJI Hiroyuki



^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: long encoded filename in mime part is truncated and not decoded
  2007-06-12  2:29 long encoded filename in mime part is truncated and not decoded NAKAJI Hiroyuki
@ 2007-06-12  4:27 ` Katsumi Yamaoka
  2007-06-12  8:29   ` NAKAJI Hiroyuki
  0 siblings, 1 reply; 5+ messages in thread
From: Katsumi Yamaoka @ 2007-06-12  4:27 UTC (permalink / raw)
  To: ding

>>>>> In <873b0x3nxi.fsf@roddy.4407.kankyo-u.ac.jp>
>>>>>	NAKAJI Hiroyuki <nakaji@jp.freebsd.org> wrote:

> Japanese people love to name files using Japanese characters and the
> filename is usually looooooooooooooooooooooooooooooooooooooong. And when
> a user attached this long-named file, some mail clients truncates the
> excoded filename.

> For example, when user uses

> User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.0; ja-JP; rv:1.4) Gecko/20030624 Netscape/7.1 (ax)

> and such a long-named file is attached as mime-multipart, in article
> buffer it is shown like this:

> [3. application/msword; 44新規学習ニーズ対応プログラム支援経費=?ISO-2022-JP?B?WxskQjpOQnJAKRsoQl0bJEIhS]...

> and then, when I typed 'o' at this part, the file is saved as
> 44新規学習ニーズ対応プログラム支援経費=?ISO-2022-JP?B?WxskQjpOQnJAKRsoQl0bJEIhS

Does such a mailer (i.e., Netscape 7.1) display and extract it
correctly?  If so, Gnus will have to somehow do it, too.  I don't
believe any mailer always can do it, though.  Anyway, he probably
sends such ones not only to his men but also to his bosses, so he
will lose his post sooner or later.  It's only a matter of time.
;-p

> I don't like it. I want the file to be saved as
> 44新規学習ニーズ対応プログラム支援経費[採択制]

> Is it possible to decode this kind of truncated loooong filename in
> Gnus? I got "44新規学習ニーズ対応プログラム支援経費[採択制]" with adding
> "=?=" after "...EIhS".

> Of cource, I don't mind adding ".doc" after "...[採択制]" by hand when I
> save this part.

Although efforts to fix it might all go for nothing even if the
problem is simply that exactly the "=?=" is always lacking, could
you show the raw header of the part in question?

Regards,



^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: long encoded filename in mime part is truncated and not decoded
  2007-06-12  4:27 ` Katsumi Yamaoka
@ 2007-06-12  8:29   ` NAKAJI Hiroyuki
  2007-06-12 10:01     ` Katsumi Yamaoka
  0 siblings, 1 reply; 5+ messages in thread
From: NAKAJI Hiroyuki @ 2007-06-12  8:29 UTC (permalink / raw)
  To: ding

>>>>> In <b4m1wghdcgk.fsf@jpl.org> 
>>>>>	Katsumi Yamaoka <yamaoka@jpl.org> wrote:

> Does such a mailer (i.e., Netscape 7.1) display and extract it
> correctly?  If so, Gnus will have to somehow do it, too.  I don't
> believe any mailer always can do it, though.  Anyway, he probably
> sends such ones not only to his men but also to his bosses, so he
> will lose his post sooner or later.  It's only a matter of time.
> ;-p

The answer for your question is NO. I saw this mail with Mozilla
Thunderbird and found the filename is also "44新規学習ニーズ対応プログラム支援経費=?ISO-2022-JP?B?WxskQjpOQnJAKRsoQl0bJEIhS"

;; BTW, he is a Vice-president of the university who is probably one of
;; our bosses. :)

> Although efforts to fix it might all go for nothing even if the
> problem is simply that exactly the "=?=" is always lacking, could
> you show the raw header of the part in question?

I agree with your opinion. Adding '=?=' is not cool.

Here is the header of the mail.

User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.0; ja-JP; rv:1.4) Gecko/20030624 Netscape/7.1 (ax)
X-Accept-Language: ja
Mime-Version: 1.0
Content-Type: multipart/mixed;
 boundary="------------050601010802060300010200"

And here is the header of the part in concern.

--------------050601010802060300010200
Content-Type: application/msword;
 name="=?ISO-2022-JP?B?NDQbJEI/NzUsM1g9LCVLITwlOkJQMX4lVyVtJTAlaSVgO1kxZzdQSHEbKEI=?==?ISO-2022-JP?B?WxskQjpOQnJAKRsoQl0bJEIhS"
Content-Transfer-Encoding: base64
Content-Disposition: inline;
 filename="=?ISO-2022-JP?B?NDQbJEI/NzUsM1g9LCVLITwlOkJQMX4lVyVtJTAlaSVgO1kxZzdQSHEbKEI=?==?ISO-2022-JP?B?WxskQjpOQnJAKRsoQl0bJ"
-- 
NAKAJI Hiroyuki



^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: long encoded filename in mime part is truncated and not decoded
  2007-06-12  8:29   ` NAKAJI Hiroyuki
@ 2007-06-12 10:01     ` Katsumi Yamaoka
  2007-06-12 13:05       ` NAKAJI Hiroyuki
  0 siblings, 1 reply; 5+ messages in thread
From: Katsumi Yamaoka @ 2007-06-12 10:01 UTC (permalink / raw)
  To: ding

[-- Attachment #1: Type: text/plain, Size: 438 bytes --]

>>>>> In <87sl8x1sq3.fsf@roddy.4407.kankyo-u.ac.jp>
>>>>>	NAKAJI Hiroyuki <nakaji@jp.freebsd.org> wrote:

> And here is the header of the part in concern.

> --------------050601010802060300010200
> Content-Type: application/msword;
>  name="=?ISO-2022-JP?B?NDQbJEI/NzUsM1g9LCVLITwlOkJQMX4lVyVtJTAlaSVgO1kxZzdQSHEbKEI=?==?ISO-2022-JP?B?WxskQjpOQnJAKRsoQl0bJEIhS"

[...]

Here is a program that tries fixing of corrupted B encoded words:


[-- Attachment #2: Type: application/emacs-lisp, Size: 732 bytes --]

[-- Attachment #3: Type: text/plain, Size: 183 bytes --]


Use this with care.  It will not necessarily fix such ones,
moreover it might break correct ones.  To disable this, type
`M-x ad-unadvise RET rfc2231-parse-qp-string RET'.

Regards,

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: long encoded filename in mime part is truncated and not decoded
  2007-06-12 10:01     ` Katsumi Yamaoka
@ 2007-06-12 13:05       ` NAKAJI Hiroyuki
  0 siblings, 0 replies; 5+ messages in thread
From: NAKAJI Hiroyuki @ 2007-06-12 13:05 UTC (permalink / raw)
  To: ding

>>>>> In <b4mejkhbig2.fsf@jpl.org> 
>>>>>	Katsumi Yamaoka <yamaoka@jpl.org> wrote:

> Here is a program that tries fixing of corrupted B encoded words:

Thanks. This helps very much.

> Use this with care.  It will not necessarily fix such ones,
> moreover it might break correct ones.  To disable this, type
> `M-x ad-unadvise RET rfc2231-parse-qp-string RET'.

I'll use with care.
-- 
NAKAJI Hiroyuki



^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2007-06-12 13:05 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2007-06-12  2:29 long encoded filename in mime part is truncated and not decoded NAKAJI Hiroyuki
2007-06-12  4:27 ` Katsumi Yamaoka
2007-06-12  8:29   ` NAKAJI Hiroyuki
2007-06-12 10:01     ` Katsumi Yamaoka
2007-06-12 13:05       ` NAKAJI Hiroyuki

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).