Apache Headers

How do I remove response headers from Apache? I tried using mod_headers, and did:

Header remove Server

With no luck, so I tried:

Header set Server "Hiding"

Again, no luck. I want to be able to change these headers, because for example, Google returns:

Response Headers - http://www.google.com/

X-TR: 1
Cache-Control: private
Content-Type: text/html
Server: GWS/2.1
Date: Sun, 07 Nov 2004 05:33:57 GMT
Content-Length: 2325

Which is minimal information, helping in avoid attacks against a server.

I am using Apache2, I am also using mod_security to modify Server but that is all that I can seem to modify/remove...I tried to set Headers within the actual PHP files, but still no luck.

My current headers after trying for the last 5 hours:

Date: Sun, 07 Nov 2004 05:36:09 GMT
Server: Mine
Expires: Mon, 26 Jul 1997 05:00:00 GMT
Cache-Control: private
Keep-Alive: timeout=15, max=74
Content-Type: text/html; charset=ISO-8859-1
Connection: Keep-Alive
Transfer-Encoding: chunked

How can I turn off Keep-Alive and Connection headers? Modify the content-type header to remove the charset?
drakkarnoirAsked:
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

hernst42Commented:
You can turn off Keep-Alive by setting
KeepAlive Off
This will remove the Keep-Alive -header, but the Connection is changed to closed.

But why do you want to change Content-Type. This is needed by each browser to determin how to display the pagecorrectly.

Those information about Keep-Alive, Connection and Content-Type do not expose any information about your server, but removing/changing parts will break/slow down browsers.
0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
hernst42Commented:
very hard to say if the hints I provided helped or not as there was no feedback at all and no other comments have been made.
0
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Apache Web Server

From novice to tech pro — start learning today.

Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.