Print

Print


@esindril commented on this pull request.


In src/XrdHttp/XrdHttpProtocol.cc:

> @@ -1528,7 +1528,7 @@ int XrdHttpProtocol::StartSimpleResp(int code, const char *desc, const char *hea
   if ((bodylen >= 0) && (code != 100))
     ss << "Content-Length: " << bodylen << crlf;
 
-  if (header_to_add)
+  if (header_to_add && strlen(header_to_add))

Actually, now that you mention it probably it would be even better to protect against a huge header size being returned and it looks like the upper limit of the usual HTTP implementations is around 8kB - 16kB. If the header goes beyond this the server should probably reply: 413 Entity Too Large. But this is outside the scope of this small patch and probably up for discussion with the rest of the devs.


Reply to this email directly, view it on GitHub, or unsubscribe.
You are receiving this because you are subscribed to this thread.Message ID: <xrootd/xrootd/pull/1971/review/1350421343@github.com>

[ { "@context": "http://schema.org", "@type": "EmailMessage", "potentialAction": { "@type": "ViewAction", "target": "https://github.com/xrootd/xrootd/pull/1971#discussion_r1143354991", "url": "https://github.com/xrootd/xrootd/pull/1971#discussion_r1143354991", "name": "View Pull Request" }, "description": "View this Pull Request on GitHub", "publisher": { "@type": "Organization", "name": "GitHub", "url": "https://github.com" } } ]

Use REPLY-ALL to reply to list

To unsubscribe from the XROOTD-DEV list, click the following link:
https://listserv.slac.stanford.edu/cgi-bin/wa?SUBED1=XROOTD-DEV&A=1