logo
Apache Lounge
Webmasters

 

About Forum Index Downloads Search Register Log in RSS X


Keep Server Online

If you find the Apache Lounge, the downloads and overall help useful, please express your satisfaction with a donation.

or

Bitcoin

A donation makes a contribution towards the costs, the time and effort that's going in this site and building.

Thank You! Steffen

Your donations will help to keep this site alive and well, and continuing building binaries. Apache Lounge is not sponsored.
Post new topic   Forum Index -> Apache View previous topic :: View next topic
Reply to topic   Topic: Malformed Apache requests
Author
sudu.gsr



Joined: 29 Dec 2014
Posts: 3
Location: India, Bangalore

PostPosted: Mon 29 Dec '14 18:53    Post subject: Malformed Apache requests Reply with quote

Hi Team,

Apache version: Apache/2.2.27
OS: SunOS

I am facing an issue where the Apache requests are malformed and is causing unusual behavior with the application. We have Webcache servers in front of Apache webservers. The requests in the Webcache servers are fine but they end malformed at Apache webservers.

Request in Webcache access log: Request is well formed with GET or POST (xx.xx.xx.xx - - [Timestamp] "GET /abc/def.htm HTTP/1.1" 501 559 "referrer URL" "browser/5.0 (Linux;
U; Android 4.2.2; locale; SM-G386F Build/JDQ39) AppleWebKit/534.30 (KHTML, like Gecko) Version/4.0 Mobile Safari/534.30 " "" 0.009315)

Corresponding request at Apache webserver is malformed as
yy.yy.yy.yy xx.xx.xx.xx - - [timestamp] "jumbled_charactersGET /abc/def.htm HTTP/1.1" 501 990 "referrer URL" "-"

Some characters are getting added before the actual request ("GET /abc/def.htm HTTP/1.1") and such requests are not getting blocked/ handled at Apache but are making it to the Application servers that are behind the webserver.

Please let me know if anyone has faced such an issue and how can this be handled.

Thanks.

Regards,
SRG
Back to top
James Blond
Moderator


Joined: 19 Jan 2006
Posts: 7373
Location: Germany, Next to Hamburg

PostPosted: Fri 02 Jan '15 0:07    Post subject: Reply with quote

For me it seems that the web cache is sending the mal formed stuff to apache. I think you should look there for that issue.
What web cache are you using in front of apache?
Back to top
sudu.gsr



Joined: 29 Dec 2014
Posts: 3
Location: India, Bangalore

PostPosted: Fri 02 Jan '15 9:02    Post subject: Malformed Apache requests Reply with quote

We see that the access logs for Webcache is just fine. I don't see any malformed request is Webcache access logs. Also, that only a few requests are getting malformed at the apache end.
Btw, it is Oracle Webcache 11g.
Back to top
James Blond
Moderator


Joined: 19 Jan 2006
Posts: 7373
Location: Germany, Next to Hamburg

PostPosted: Tue 06 Jan '15 19:14    Post subject: Reply with quote

That is not what I meant. I'm guessing that the Oracle Webcache is forwarding a malformated request after processing.
Back to top
sudu.gsr



Joined: 29 Dec 2014
Posts: 3
Location: India, Bangalore

PostPosted: Wed 07 Jan '15 10:43    Post subject: Post subject: Malformed Apache requests Reply with quote

Sure...I am looking at the network dump to check what Webcache is sending to the Apache webserver.

But, is there a way to handle such malformed requests at Apache itself, rather than those requests making it to the Application servers.
Back to top
James Blond
Moderator


Joined: 19 Jan 2006
Posts: 7373
Location: Germany, Next to Hamburg

PostPosted: Thu 08 Jan '15 17:55    Post subject: Reply with quote

I haven't done it, but it should be possible via top
RequestHeader edit http://httpd.apache.org/docs/2.2/mod/mod_headers.html#requestheader
Back to top


Reply to topic   Topic: Malformed Apache requests View previous topic :: View next topic
Post new topic   Forum Index -> Apache