πŸš€ go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: borland.public.cppbuilder.internet.web
Article #791

Re: utf-8 in filename of Content-Disposition: attachment;

#791
From: Remy Lebeau (TeamB)
Date: Mon, 30 Jan 2006 18:07
29 lines
2032 bytes
"Hans Galema" <notused@notused.nl> wrote in message
news:43de245b$1@newsgroups.borland.com...

> The filename decodes to: samen met AndrοΏ½ kijken naar Pascal.jpg
>
> Is c2FtZW4gbWV0IEFuZHLDqSBraWprZW4gbmFhciBQYXNjYWwuanBn the piece that
represents this?

It is part of it.  The fields used to describe the encoding are separated by
'?', where the encoding begins with '=?' and ends with '?='.  So, the
encoding breaks down into three fields as follows:

    UTF-8
    B
    c2FtZW4gbWV0IEFuZHLDqSBraWprZW4gbmFhciBQYXNjYWwuanBn

The 'UTF-8' is the encoding used for the original data.  The 'B' is the
transmission encoding for the encoded data.  In this case, 'B' means that
base64 is used.  So, to get the original filename, you have to first decode
the contents of the third field with base64, and then decode the resulting
data with UTF-8 to get the original value.

> In my bcb5 I cannot find these functions.

They are in the Win32 API.


Gambit
Technical Details
Message-ID: <43de5578$1@newsgroups.borland.com>
Path: arc1-ca.pugleaf.net!g2news1.google.com!news1.google.com!news4.google.com!news.glorb.com!txtfeed1.tudelft.nl!tudelft.nl!txtfeed2.tudelft.nl!multikabel.net!feed20.multikabel.net!border1.nntp.ams.giganews.com!nntp.giganews.com!pe2.news.blueyonder.co.uk!blueyonder!news-peer-test!btnet!newsfeed.bt.es!caladan.landsraad.net!newsgroups.borland.com!not-for-mail
References: <43de245b$1@newsgroups.borland.com>

Show Full Headers
Complete Article Headers
X-Google-Thread: feeec,9857a2e9199d6815
X-Google-Attributes: gidfeeec,public
X-Google-Language: ENGLISH,ASCII
From: "Remy Lebeau \(TeamB\)" <no.spam@no.spam.com>
Newsgroups: borland.public.cppbuilder.internet.web
References: <43de245b$1@newsgroups.borland.com>
Subject: Re: utf-8 in filename of Content-Disposition: attachment;
Date: Mon, 30 Jan 2006 10:07:59 -0800
Lines: 31
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.2800.1409
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1409
NNTP-Posting-Host: 68.69.17.41
Message-ID: <43de5578$1@newsgroups.borland.com>
X-Trace: newsgroups.borland.com 1138644344 68.69.17.41 (30 Jan 2006 10:05:44 -0700)
Path: arc1-ca.pugleaf.net!g2news1.google.com!news1.google.com!news4.google.com!news.glorb.com!txtfeed1.tudelft.nl!tudelft.nl!txtfeed2.tudelft.nl!multikabel.net!feed20.multikabel.net!border1.nntp.ams.giganews.com!nntp.giganews.com!pe2.news.blueyonder.co.uk!blueyonder!news-peer-test!btnet!newsfeed.bt.es!caladan.landsraad.net!newsgroups.borland.com!not-for-mail