Print

Print


Hello,

In the following scenario, where the "Stat request" of a file returns a larger size than the actual "read request", the XrdHttp component would enter a loop.

To reproduce this, perform a GET request on a "script file". The stat on the script will return a fixed size (e.g 4096), but upon the read request, the actual output will be different. At this point, XrdHttp enters a loop trying to read the remaining bytes.

In my particular case, I am accessing the `/proc/whoami` script on an EOS system (logs attached).

This change prevents this scenario and abruptly interrupts the HTTP connection.

[xrdhttp.log](https://github.com/xrootd/xrootd/files/2098289/xrdhttp.log)
You can view, comment on, or merge this pull request online at:

  https://github.com/xrootd/xrootd/pull/744

-- Commit Summary --

  * Prevent issue in scenario where stat request returns larger size than the actual read request

-- File Changes --

    M src/XrdHttp/XrdHttpReq.cc (9)

-- Patch Links --

https://github.com/xrootd/xrootd/pull/744.patch
https://github.com/xrootd/xrootd/pull/744.diff

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/xrootd/xrootd/pull/744

########################################################################
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