You are here
Mike Landeck - Wed, 2019/06/05 - 06:54
I'm stumped. Can anyone point me to information on how to change the server name in the banner? For example, I'd like:
HTTP/1.1 200 OK
Date: Wed, 05 Jun 2019 02:56:12 GMT
--> Server: Apache <--
Content-Type: text/html; charset=UTF-8
to be:
HTTP/1.1 200 OK
Date: Wed, 05 Jun 2019 02:56:12 GMT
--> Server: Something Else <--
Content-Type: text/html; charset=UTF-8
Thank you!
Forum:
TBH, I've never tried it, but it should be possible
My suspicion is that you didn't find anything of value when searching because the info you wish to modify is generally referred to as the "header" rather than the "banner".
So with that in mind a quick google turned up this Unix StackExchange Q&A.
Please be aware that it looks like the question is specifically related to Red Hat (or a derivative). Debian (the basis of TurnKey) has the Apache config laid out a little differently. Rather than a monolithic httpd.conf file (as per Apache upstream and used by Red Hat et al) Debian splits the Apache config up into multiple files. They all reside within the /etc/apache2 directory. Please also note that any directives set multiple times within any of the config will be overridden by later ones. I.e. the last setting of a particular directive will be the one that is used by Apache.
I haven't had a chance to check, but it seems that this particular answer may be your best bet. TurnKey comes with Apache mod_security pre-installed and enabled, so according to that answer, the directives you'd likely wish to modify (ServerTokens and ServerSignature ?) should be found in /etc/apache2/conf-available/security.conf. After you've modified those as you wish, you'll need to restart Apache to apply the updated config:
Good luck and please post back to let us know how you get on.
Thank you!
That was exactly what I was looking for.
Add new comment