Improve Apache Web Server Security: Use ServerTokens and ServerSignature to Disable Header Mejorar el servidor web Apache Seguridad: ServerTokens uso y ServerSignature para desactivar cabecera
When Apache HTTPD web server generates any web pages or error pages, some important information about the version and other details implemented on the system are displayed in th web site server header. Cuando Apache httpd servidor web genera páginas web o páginas de error, algunos datos importantes sobre la versión y otros detalles aplicado en el sistema se muestran en ª sitio web del servidor de cabecera. For example, the information text may be like this: Por ejemplo, la información que el texto puede ser como este:
Server: Apache/1.3.37 (Unix) mod_auth_passthrough/1.8 mod_log_bytes/1.2 mod_bwlimited/1.4 FrontPage/5.0.2.2635.SR1.2 mod_ssl/2.8.28 OpenSSL/0.9.7a PHP-CGI/0.1b Server: Apache/1.3.37 (Unix) mod_auth_passthrough/1.8 mod_log_bytes/1.2 mod_bwlimited/1.4 FrontPage/5.0.2.2635.SR1.2 mod_ssl/2.8.28 OpenSSL/0.9.7a PHP-CGI/0.1b
Server: Apache/2.0.53 (Ubuntu) PHP/4.3.10-10ubuntu4 Server at xx.xx.xx.xx Port 80 Server: Apache/2.0.53 (Ubuntu) Server PHP/4.3.10-10ubuntu4 a xx.xx.xx.xx Port 80
The line in the server header expose important version and variant information about the Linux operating system and Apache software used on the machine, indirectly expose the possible security holes that are existed to the hackers, or at least make malicious attackers easier to identify your system for available attack points. La línea en el servidor de cabecera importante exponer la versión y la variante información sobre el sistema operativo Linux y Apache software usado en la máquina, de manera indirecta exponer las posibles agujeros de seguridad que existen para los hackers, o al menos hacer más fácil atacantes maliciosos para identificar su sistema de dispone de puntos de ataque.
To ensure that the Apache HTTP web server does not broadcast this message to the whole world publicly and fix possible security issue, modify these two directives ServerTokes and ServerSignature in httpd.conf configuration file. Para asegurarse de que el Apache HTTP del servidor web no difunde este mensaje a todo el mundo público y fijar posible problema de seguridad, modificar estas dos directivas ServerSignature y ServerTokes en httpd.conf fichero de configuración.
- Login as root user or perform a sudo to the web server. Inicio de sesión como usuario root o realizar una sudo al servidor web.
- Open and edit httpd.conf or apache2.conf (in Apache 2) with vi or other text editor. Abrir y editar httpd.conf o apache2.conf (en Apache 2), con vi u otro editor de texto. The Apache configuration normally located in /etc/httpd/conf/ or /etc/apache2/ or /etc/apache/ (for Apache1.3) depending on which Unix you’re using. La configuración de Apache normalmente situado en / etc / httpd / conf / o / etc/apache2 / o / etc / apache / (para Apache1.3), en función de que Unix que se esté usando.
- Locate the line with ServerTokens . Ubique la línea con ServerTokens. You can perform a search by typing “/ServerTokes” and hit Enter. Puede realizar una búsqueda escribiendo "/ ServerTokes" y pulse Enter.
- In Apache 1.3, you will likely to see a line starts with #ServerTokes Full In this case, remove or delete the # character (by pressing d key). En Apache 1,3, es probable que para ver una línea que comienza con # ServerTokes íntegro En este caso, eliminar o borrar el carácter # (presionando d clave). Also modify the Full to become Prod (press r key to replace one character, or R to replace multiple characters), so that the line becomes ServerTokens Prod . También modificar el íntegro de convertirse Prod (r prensa clave para reemplazar un carácter, o R para sustituir múltiples caracteres), de modo que la línea se convierte en ServerTokens Prod. In Apache 2.0 or 2.2, the line normally does not exist. En Apache 2,0 o 2,2, la línea que normalmente no existe. So the search will fail. Por lo tanto, la búsqueda fallará. In this case, go to the bottom of config file, and add the new line with the following text. En este caso, ir al fondo del archivo de configuración, y añadir la nueva línea con el siguiente texto. You can add new line by pressing o key. Puede añadir nuevas líneas de prensado o clave.
ServerTokens Prod ServerTokens Prod
- Next, search for ServerSignature. A continuación, búsqueda de ServerSignature. In Apache13, the line should just above the line of ServerTokens. En Apache13, la línea justo por encima de la línea de ServerTokens. Edit the line so that it looks like this, and in Apache2 which doesn’t already have this line, add in at new one. Modificar la línea a fin de que se parece a esto, y en Apache 2 que no tiene esta línea, a añadir a una nueva.
ServerSignature Off ServerSignature Off
- By now the Apache configuration file should have this two directives set as below: Por ahora el archivo de configuración de Apache debe tener presente dos directivas establece de la siguiente forma:
ServerSignature Off ServerSignature Off
ServerTokens Prod ServerTokens ProdThe first line “ServerSignature Off” instructs Apache not to display a trailing footer line under server-generated documents (error messages, mod_proxy ftp directory listings, mod_info output, and etc) which displays server version number, ServerName of the serving virtual host, email setting, and creates a “mailto:” reference to the ServerAdmin of the referenced document. La primera línea "ServerSignature Off" no instruye a Apache para mostrar una línea de pie de página a remolque en virtud de servidor generados por los documentos (mensajes de error, mod_proxy ftp listados de directorios, mod_info salida, y etc) que muestra el número de la versión servidor, ServerName de la máquina virtual que actúa, e-mail configuración, y crea un "mailto:" referencia a la ServerAdmin del documento de referencia.
The second line “ServerTokens Prod” configures Apache to return only Apache as product in the server response header on very page request, suppressing OS, major and minor version info. La segunda línea "ServerTokens Prod" configura Apache para regresar sólo como producto de Apache en la cabecera de respuesta del servidor a muy solicitud de la página, la supresión de OS, mayor y menor versión info.
- Save and close the config file by pressing Shift-Colon, and then type wq keys, and hit Enter. Guardar y cerrar el fichero de configuración mediante Mayúsculas-Colón, y luego wq tipo de llaves, y pulse Enter.
- Restart Apache. Reinicia Apache. Typical command is service httpd restart or /etc/init.d/apache2 restart . Típico comando es el servicio httpd restart o / etc/init.d/apache2 restart.
- Now, you will get only the Apache in the server response header: Ahora, usted obtendrá sólo el Apache en la cabecera de respuesta del servidor:
Server: Apache Server: Apache
IMPORTANT : This is a machine translated page which is provided "as is" without warranty. IMPORTANTE: Se trata de una máquina que traduzca la página se proporciona "tal cual" sin garantía. Machine translation may be difficult to understand. La traducción automática puede resultar difícil de entender. Please refer to Por favor, consulte original English article artículo original Inglés whenever possible. siempre que sea posible.
Share and contribute or get technical support and help at Compartir y contribuir o recibir apoyo técnico y ayudar a My Digital Life Forums Mi vida digital Foros .
Related Articles Artículos relacionados
- Installing Web Server in FreeBSD 6.0 with Apache 2.2, MySQL 5.0 and PHP 5 - Part 4 Instalación de Web Server en FreeBSD 6,0 con Apache 2,2, 5,0 MySQL y PHP 5 - Parte 4
- Apache Status (whm-server-status) in cPanel WebHost Manager Returns Blank Page Condición Apache (servidor-WHM-estado) en cPanel WebHost Manager Devoluciones página en blanco
- Easily Set Up Web Server with XAMPP Fácil de configurar tu servidor con XAMPP
- Remove and Uninstall or Disable ModSecurity (mod_security) Retire y Desinstalar o Desactivar ModSecurity (mod_security)
- Starting Apache HTTPD Failed Due to Cannot Open or No Such mod_bwlimited, mod_log_bytes or mod_bandwidth Files A partir de Apache httpd Debido a Error No se puede abrir o No Such mod_bwlimited, mod_log_bytes o mod_bandwidth Archivos
- cPanel WHM Failed to Receive Status Information From Apache Error cPanel WHM No se ha podido recibir la información de estado de error de Apache
- winnt_accept: Asynchronous AcceptEx failed Error in Apache Log winnt_accept: asíncrona AcceptEx no Error en registro de Apache
- Apache Warn NameVirtualHost *:80 Has No VirtualHosts Error When Start Apache advertir NameVirtualHost *: 80 no tiene VirtualHosts error al comienzo
- Install Web Server in Windows XP with Apache2, PHP5 and MySQL4 - Part 2 Instalar Web Server en Windows XP con Apache 2, PHP5 y MySQL4 - Parte 2
- Auto Shutdown and Restart Apache HTTPD Service Daemon at Preset Time Auto cierre y reinicie el servicio de Apache httpd demonio en tiempo preestablecido


















