DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUGĀ·
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://issues.apache.org/bugzilla/show_bug.cgi?id=40306>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED ANDĀ·
INSERTED IN THE BUG DATABASE.

http://issues.apache.org/bugzilla/show_bug.cgi?id=40306


[EMAIL PROTECTED] changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
         OS/Version|Linux                       |All




------- Additional Comments From [EMAIL PROTECTED]  2006-08-27 05:14 -------
After going over this again, body.toString() wasn't returning null after all,
but the POST parameter values were still missing. I debugged the coyoteRequest
and noticed that the contentLength was equal to -1 upon entering the
restoreRequest() method of FormAuthenticator when going over the http connector
(8080). When going over AJP it was set to 0. 

This causes a problem in
org.apache.catalina.connector.Request.parseParameters(). Before attempting to to
find POST parameters, it calls org.apache.coyote.Request.getContentLength()
which doesn't look at the content-length header when the current value of
contentLength > -1. Being that the current value equals 0, no parameters were
parsed.  

At any rate, the following code fixes the problem.

org.apache.coyote.ajp.AjpAprProcessor.java (5.5.16), starting at line 579:

        } else if (actionCode == ActionCode.ACTION_REQ_SET_BODY_REPLAY) {

            // Reset the content length on the saved request.
            request.setContentLength(-1);
            // Set the given bytes as the content
            ByteChunk bc = (ByteChunk) param;
            bodyBytes.setBytes(bc.getBytes(), bc.getStart(), bc.getLength());
            first = false;
            empty = false;
            replay = true;

        }
 
I would greatly appreciate it if a commiter would take a look at this.

-- 
Configure bugmail: http://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to