tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Franck Borel <>
Subject Re: Filter GET and POST
Date Wed, 26 Sep 2007 14:25:29 GMT
Hi Christopher,

thank you very much for your answer.

>> i have a problem with an application that only accept GET requests. Now,
>> I would like to know, if there is any possibility to write a filter, who
>> is able to change the method from POST to GET.
> What do you mean by that? Do you just want to change the return value of
> HttpServletRequest.getMethod? You can certainly do that easily.
> Do you want to convert POST parameters to GET parameters? That is a bit
> tougher, but is possible. 
Yes, I think this is the only possibility. I found no example how this could be 
done. Any idea?

> I'm not sure why you'd want to do this, since
> servlets do not really distinguish between GET and POST parameters --
> the API abstracts that complexity away from your code.

If I change the request from POST to GET the Servlet works. I have no
possibility to change the Servlet behind.

>> I see that the FORM-Authentication could speek GET after authentication
>> with POST method. Is there anybody outwhere, who knows how this was done?
> Given that the Tomcat source code is available, you could always look in
> there for inspiration!


-- Franck

To start a new topic, e-mail:
To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message