You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@mina.apache.org by "Jeff MAURY (JIRA)" <ji...@apache.org> on 2014/09/07 17:45:29 UTC

[jira] [Commented] (DIRMINA-965) HttpServerDecoder is broken in certain condition

    [ https://issues.apache.org/jira/browse/DIRMINA-965?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14124934#comment-14124934 ] 

Jeff MAURY commented on DIRMINA-965:
------------------------------------

Fixed in 2.0 by commit f029e2326f33c5f11c359abe9be55dfacb530813

> HttpServerDecoder is broken in certain condition
> ------------------------------------------------
>
>                 Key: DIRMINA-965
>                 URL: https://issues.apache.org/jira/browse/DIRMINA-965
>             Project: MINA
>          Issue Type: Bug
>          Components: Protocol - HTTP
>    Affects Versions: 2.0.7
>            Reporter: Jeff MAURY
>              Labels: decoder, http
>             Fix For: 2.0.8
>
>
> HttpServerDecoder is broken in the case an HTTP request is received in two separate packets and the first one is not big enough to contain the header.
> So, when the first packed is received, the state is switch to HEAD, and the incoming packed is saved in the context.
> When the second packet is received, then the header is decoded and written to the output and the state is switched to BODY. But as the incoming buffer has been accumulated into with the context buffer, its remaining is 0 and the caller will not call the decoder again. So when the next request is received, the state will be BODY and CRASH!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
> We should check if this also applies to 3.0



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)