Print

Print


Consider the following "conversation":
```
    => PUT /somewhere/test_webdav_access_9 HTTP/1.1
    => User-Agent: PycURL/7.19.7
    => Host: xrootd006.example.com:1094
    => Accept: */*
    => Transfer-Encoding: chunked
    => Expect: 100-continue
    => 
    <= HTTP/1.1 100 Unknown
    <= Connection: Keep-Alive
    <= Content-Length: 0
    => 79
    => This is a test file generated by the nagios probe check-webdav from package nagios-plugins-webdav. It is safe to delete.
    => 
    => 0
    => 
    <= HTTP/1.1 200 OK
    <= Connection: Keep-Alive
    <= Content-Length: 3
    <= 
    <= :-)
```
The end result is an empty file `/somewhere/test_webdav_access_9` on the storage. 

According to RFC 2616 in (4.4 Message Length):
```
   If a request contains a message-body and a Content-Length is not given,
   the server SHOULD respond with 400 (bad request) if it cannot
   determine the length of the message, or with 411 (length required) if
   it wishes to insist on receiving a valid Content-Length.

   All HTTP/1.1 applications that receive entities MUST accept the
   "chunked" transfer-coding (section 3.6), thus allowing this mechanism
   to be used for messages when the message length cannot be determined
   in advance.
```
So for HTTP 1.1 compatibility, XRootD must accept the content and determine the size on the fly. 

This test was done with XRootD 4.9.0. 

-- 
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/issues/915

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