Improve Apache Web Server Security: Use ServerTokens and ServerSignature to Disable Header Meningkatkan Apache Web Server Security: Gunakan ServerTokens dan ServerSignature ke Nonaktifkan Header
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. Ketika web server Apache httpd menghasilkan suatu halaman web atau kesalahan halaman, beberapa informasi penting tentang versi dan rincian lainnya yang diimplementasikan pada sistem akan ditampilkan di situs web server th header. For example, the information text may be like this: Misalnya, informasi teks mungkin seperti ini:
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 di 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. Baris dalam server header menelanjangi penting versi dan varian informasi tentang sistem operasi Linux dan perangkat lunak Apache digunakan di komputer, langsung menelanjangi kemungkinan lubang keamanan yang ada di hacker, atau setidaknya membuat penyerang berbahaya yang lebih mudah untuk mengidentifikasi sistem Anda untuk tersedia serangan poin.
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. Untuk memastikan bahwa Apache HTTP web server tidak menyiarkan pesan ini ke seluruh dunia publik dan memperbaiki kemungkinan masalah keamanan, memodifikasi kedua ServerTokes dan arahan ServerSignature dalam konfigurasi file httpd.conf.
- Login as root user or perform a sudo to the web server. Login sebagai root atau melakukan sudo ke web server.
- Open and edit httpd.conf or apache2.conf (in Apache 2) with vi or other text editor. Buka dan edit httpd.conf atau apache2.conf (di Apache 2) dengan vi atau editor teks. 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. Konfigurasi Apache yang biasanya terletak di / etc / httpd / conf / atau / etc/apache2 / atau / etc / apache / (untuk Apache1.3), tergantung pada Unix yang Anda gunakan.
- Locate the line with ServerTokens . Cari baris dengan ServerTokens. You can perform a search by typing “/ServerTokes” and hit Enter. Anda dapat melakukan pencarian dengan mengetikkan "/ ServerTokes" dan tekan 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). Dalam Apache 1.3, Anda akan cenderung melihat baris dimulai dengan # ServerTokes Penuh Dalam hal ini, hapus atau menghapus karakter # (dengan menekan tombol d). 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 . Juga memodifikasi penuh untuk menjadi Prod (r tekan tombol untuk menggantikan satu karakter, atau R untuk mengganti beberapa karakter), sehingga menjadi baris ServerTokens Prod. In Apache 2.0 or 2.2, the line normally does not exist. Dalam Apache 2.0 atau 2.2, baris biasanya tidak ada. So the search will fail. Maka pencarian akan gagal. In this case, go to the bottom of config file, and add the new line with the following text. Dalam hal ini, pergi ke bagian bawah file konfigurasi, dan menambahkan baris baru dengan teks. You can add new line by pressing o key. Anda dapat menambahkan baris baru dengan menekan tombol o.
ServerTokens Prod ServerTokens Prod
- Next, search for ServerSignature. Selanjutnya, mencari ServerSignature. In Apache13, the line should just above the line of ServerTokens. Dalam Apache13, baris harus tepat di atas baris 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. Edit baris sehingga seperti ini, dan di apache2 yang sudah tidak ada baris ini, tambahkan pada baru.
ServerSignature Off ServerSignature Off
- By now the Apache configuration file should have this two directives set as below: Sekarang oleh file konfigurasi Apache yang harus ada dua arahan ini ditetapkan sebagai berikut:
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. Baris pertama "ServerSignature Off" instructs Apache untuk tidak menampilkan trailing footer di bawah garis server dihasilkan dokumen (pesan error, listing mod_proxy direktori ftp, mod_info output, dan sebagainya) yang menampilkan nomor versi server, server yang melayani virtual host, email pengaturan, dan menciptakan sebuah "mailto:" merujuk pada ServerAdmin dirujuk dari dokumen.
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. Kedua baris "ServerTokens Prod" untuk kembali mengkonfigurasi Apache Apache hanya sebagai produk di server respon header pada halaman sangat permintaan, suppressing OS, besar dan kecil versi info.
- Save and close the config file by pressing Shift-Colon, and then type wq keys, and hit Enter. Menyimpan dan menutup file konfigurasi dengan menekan Shift-Colon, dan kemudian ketik WQ kunci, dan tekan Enter.
- Restart Apache. Restart Apache. Typical command is service httpd restart or /etc/init.d/apache2 restart . Khas perintah adalah layanan httpd restart atau / etc/init.d/apache2 restart.
- Now, you will get only the Apache in the server response header: Sekarang, anda akan mendapatkan hanya Apache di server respon header:
Server: Apache Server: Apache
IMPORTANT : The page is machine translated and provided "as is" without warranty. PENTING: Halaman yang diterjemahkan mesin dan diberikan "sebagaimana adanya" tanpa jaminan. Machine translation may be difficult to understand. Mesin terjemahan mungkin sulit dimengerti. Please refer to Silakan merujuk ke original English article artikel asli Inggris whenever possible. bila memungkinkan.
Related Articles Artikel Terkait
- Apache Status (whm-server-status) in cPanel WebHost Manager Returns Blank Page Status apache (whm-server-status) di cPanel webhost Manager Returns Blank Page
- Installing Web Server in FreeBSD 6.0 with Apache 2.2, MySQL 5.0 and PHP 5 - Part 5 Instalasi Web Server di FreeBSD 6.0 with Apache 2.2, PHP MySQL 5,0 dan 5 - Bagian 5
- Request URL /server-status or 404 Page Not Found Apache Error Meminta URL / server-status atau 404 Halaman Tidak Ditemukan Apache Error
- Installing Web Server in FreeBSD 6.0 with Apache 2.2, MySQL 5.0 and PHP 5 - Part 4 Instalasi Web Server di FreeBSD 6.0 with Apache 2.2, PHP MySQL 5,0 dan 5 - Part 4
- Starting Apache HTTPD Failed Due to Cannot Open or No Such mod_bwlimited, mod_log_bytes or mod_bandwidth Files Memulai Apache httpd Gagal Karena Cannot Terselesaikan atau Tidak seperti mod_bwlimited, mod_log_bytes atau mod_bandwidth File
- cPanel WHM Failed to Receive Status Information From Apache Error cPanel WHM Gagal Menerima Informasi Status Dari Apache Error
- winnt_accept: Asynchronous AcceptEx failed Error in Apache Log winnt_accept: Asynchronous AcceptEx gagal di Apache Error Log
- Install Web Server in Windows XP with Apache2, PHP5 and MySQL4 - Part 2 Instal Web Server pada Windows XP dengan apache2, PHP5 dan MySQL4 - Part 2
- Installing Web Server in FreeBSD 6.0 with Apache 2.2, MySQL 5.0 and PHP 5 - Part 3 Instalasi Web Server di FreeBSD 6.0 with Apache 2.2, PHP MySQL 5,0 dan 5 - Bagian 3
- Fix Internal Server Error When Accessing Easy Apache in cPanel WebHosting Manager Perbaiki Internal Server Error Ketika Mengakses Mudah Apache WebHosting Manager di cPanel










































November 17th, 2008 14:58 November 17, 2008 14:58
Many thanks, i have been using the ServerSignature Off for long time now, but the second one is quite new. Banyak terima kasih, saya telah menggunakan ServerSignature Off sekarang untuk jangka waktu lama, namun kedua adalah cukup baru.
Do you know how you can actually edit the serversignature so you will decide which information to send in case of an error? Apakah Anda tahu bagaimana Anda bisa mengedit serversignature sebenarnya sehingga Anda akan memutuskan untuk mengirim informasi yang jika terjadi kesalahan?
October 24th, 2008 17:00 24 Okt 2008 17:00
It's really useful article to secure your dedicated web servers. Ini sangat berguna untuk membuat artikel yang aman dedicated server web Anda. The information provided is easy to make changes on the server. Informasi yang sangat mudah untuk melakukan perubahan pada server.