Hi everybody,
I'm writing an application that creates multiple non-blocking SSL connections
to an https server, in each one I send a request and
read the server's response. my problem is, whatever I do, I can't
determine when the response data is finished. here's part of my code
responsible
Sockets (SSL or otherwise) are layer-3 objects while content is a layer-7
object. To get an accurate end-of-content marker, you'll need to parse the
output, buts since you are using the https protocol, that's going to be
easy.
Essentially, parse out the Content-Length header and read that many
Matthew Donald scripsit:
Sockets (SSL or otherwise) are layer-3 objects while content is a
layer-7
object. To get an accurate end-of-content marker, you'll need to parse the
output, buts since you are using the https protocol, that's going to be
easy.
Essentially, parse out the
Hi Matthew,
but from what I know, not all HTTP responses have Content-Length field.
responses with chunked payload are one of them. what can I do then?
Thank you.
On Saturday, January 11, 2014 1:23 PM, Matthew Donald
matthew.b.don...@gmail.com wrote:
Sockets (SSL or otherwise) are
When in doubt, use the source - or in this case RFC2616
ยง4.4.http://www.w3.org/Protocols/rfc2616/rfc2616-sec4.html#sec4.4
TL;DR version - the length is indicated by one of three situations:
1. A Content-Length header exists
2. Transfer-Encoding is chunked, in which case each chunk (there can be