curl-library
RE: Problem with binary data
Date: Fri, 31 Oct 2003 17:31:50 +0100
On Oct 31, 17:16, "Sharma, Amit" wrote:
>I would think that encoding is necessary for the similar reason why we do
>MIME encoding/ base64 encoding prior to transmission. Though am not an
>expert to comment on this, however, we have faced problems if data is sent
>over network and involving multi OS without encoding the binary content.
MIME- and base64-encodings are mainly mail-formats, and they are used
for basically two reasons:
1) When data can mean different things, e.g. charsets: MIME creates a
dataset with its own interpretation rules encoded right into the data.
2) When you want to transfer data over a medium which cannot transfer
binary data reliably, either because it's 7-bit (some mail programs)
or because displaying raw binary data would crash the application (the
rest of the mail programs :-)
>Am not an expert of HTTP either so could anybody suggest if there is a
>difference in the way in which HTTP handles data? How does it treat binary
>data??
HTTP handles binary data just fine, it solves the data interpretation
problem nicely by sending Content-Type: headers ahead of the actual
data. You don't ever really need to encode the data in e.g. base64
at all.
-Tor
-------------------------------------------------------
This SF.net email is sponsored by: SF.net Giveback Program.
Does SourceForge.net help you be more productive? Does it
help you create better code? SHARE THE LOVE, and help us help
YOU! Click Here: http://sourceforge.net/donate/
Received on 2003-10-31