How to disable X-Powered-By on an OVH server using apache?

I tried to disable the like X-Powered-By, and Serverto provide security by adding the following to my .htaccess in OVH-connected server.

<IfModule mod_headers.c>
  # Security disable headers. http://www.shanison.com/2012/07/05/unset-apache-response-header-protect-your-server-information/
  Header unset Server
  Header unset X-Powered-By
</IfModule>

But this will not work, I still get these headers when starting HTTP requests. What for? This is not possible because somehow mod_headers.c is not loading based on a mutual server?

+4
source share
1 answer

There is also a PHP function that can do this:

<?php
header_remove("X-Powered-By");
?>

http://php.net/manual/en/function.header-remove.php

Hope for this help

+1
source

All Articles