SlideShare uma empresa Scribd logo
1 de 26
APACHE 2
Secure HTTP With Apache Web Server
By GOODLE CREW
Web Server
 Adalah suatu daemon yang berfungsi
menerima request melalui protocol http
baik dari local maupun dari internet
 Informasi yang direquest oleh web
browser bisa berupa file yang ada dalam
storage atau meminta server untuk
melakukan funsgi tertentu
 IIS (web server untuk html & asp ).Bisa jalan di
OS Windows
 APACHE webserver (web server untuk
html,php,asp,jsp, dsb).Bisa jalan di OS Windows
dan LINUX. Sifatnya modular dengan
ditambahkan libapache2
Macam Web Server
 HTTPS adalah varian dari protocol HTTP
dimana user mengakses dengan https://
 Data yang dikirim ke server adalah data
yang terenkripsi.
 Enkripsi yang digunakan adalah enkripsi
SSL (Secure socket Layer).
 Menggunakan TCP port 443.
APACHE Web Server dengan HTTPS
Ilustrasi Koneksi
HTTP vs HTTPS
 Install apache2 dan modul PHP4
• # apt-get install apache2 php4 libapache2-mod-
php4
 Buat Duplikat dari file:
/etc/apache2/sites-available/default
• # cp /etc/apache2/sites-available/default
/etc/apache2/sites-available/website-ssl
 Buat link untuk mengaktifkan modul ssl
saat apache di load
• # a2ensite
• Masukkan “website-ssl”
Mengkonfigurasi HTTPS
Mengkonfigurasi HTTPS
 Mengaktifkan modul php4
• a2enmod
• dijawab dengan “php4”
 mengaktifkan modul ssl
• a2enmod
• dijawab dengan “ssl”
 Kemudian Edit
• /etc/apache2/sites-enabled/website-ssl
NameVirtualHost *:443
<VirtualHost *:443>
SSLEngine On
SSLCertificateFile /etc/apache2/ssl/apache.pem
...
</VirtualHost>
Mengkonfigurasi HTTPS
 Generate Sertifikat anda sendiri dengan
• # apache2-ssl-certificate
• kalo apache2-ssl-certificate tidak ada gunakan :
• # mkdir /etc/apache2/ssl
• # openssl req $@ -new -x509 -days 365 -nodes -out
/etc/apache2/ssl/apache.pem -keyout
/etc/apache2/ssl/apache.pem
• Kemudian anda akan diminta memasukkan kode
negara(ID),State atau propinsi,Nama
Kota,Company,Section Unit,Domain,alamat email
Membuat Sertikat SSL
 Menambahkan Port Listen Untuk
SSL,untuk melakukanya edit file:
• /etc/apache2/ports.conf
 Tambahkan Baris :
• Listen 443
Mengkonfigurasi HTTPS
 Restart APACHE2
• /etc/init.d/apache2 restart
Mengkonfigurasi HTTPS
 Buka web browser
 Cobalah ketikkan
https://localhost/
Mencoba Setting HTTPS
Tampilan HTTPS
Tampilan HTTP biasa
mod-security
Mengkonfigurasi mod-security
 Mod-security ???
• Bagaimana cara anda untuk membatasi SQL
injection, mendefinisikan hanya satu web
browser saja yg boleh akses, jumlah data, dll...
--> membatasi lewat aplikasi
• Apache2 menyediakan modul
• libapache2-mod-security
Mengkonfigurasi mod-security
 Install :
• # apt-get install libapache2-mod-security
 Mengaktifkan module
• a2enmod
• isi dengan “mod-security”
Mengkonfigurasi mod-security
 Copy contoh konfigurasi
• # cd /etc/apache2/conf.d
• # cp /usr/share/doc/libapache2-mod-
security/examples/httpd2.conf.example-full
mod-security.conf
 Restart apache
• # /etc/init.d/apache2 restart
Uji Coba mod-security
 Jalankan aplikasi testingnya
• # cd /usr/share/mod-security/test/
• # ./run-test.pl localhost *.test
 Buka website dengan webbrowser “w3m”
dan mozilla
• # w3m http://localhost
• akan terjawab IIS ... lo bukannya tadi install apache2
???
Mod-chroot
Chroot
 chroot – change
root directory
• dir /var/www/
berubah seolah-
olah menjadi dir “/”
 apache2 jalan di
chroot
Mengkonfigurasi mod-chroot
 Install module chroot
• # apt-get install libapache2-mod-chroot
 Aktifkan module chroot
• # a2enmod
• isi dengan “mod_chroot”
Mengkonfigurasi mod-chroot
 Buat konfigurasi untuk mod-chroot, bisa di
/etc/apache2/conf.d
• # cd /etc/apache2/conf.d
• vim mod-chroot
<IfModule mod_chroot.c>
LoadFile /lib/libgcc_s.so.1
</IfModule>
ChrootDir /var/www
Mengkonfigurasikan mod-chroot
 Buat dir untuk chroot
• # mkdir -p /var/www/var/run
 Jalankan apache2
• # /etc/init.d/apache2 start
 Rubah pidfile
• # cd /var/run
• # ln -s /var/www/var/run/apache2.pid
apache2.pid
Mengkonfigurasi mod-chroot
 buat file coba.php
<?
system(“ls /etc”);
?>
 Script php untuk melihat isi dir /etc
 Bandingkan hasilnya antara ada mod-
chroot dan tidak menggunakan mod-
chroot
Selamat mencoba,...

Mais conteúdo relacionado

Mais procurados

TugasII SO2 Install Apache, PHP Dan MySQL Pada CentOS 7 (LAMP)
TugasII SO2 Install Apache, PHP Dan MySQL Pada CentOS 7 (LAMP)TugasII SO2 Install Apache, PHP Dan MySQL Pada CentOS 7 (LAMP)
TugasII SO2 Install Apache, PHP Dan MySQL Pada CentOS 7 (LAMP)ApriyantoGafur
 
Konfigurasi https pada debian 7
Konfigurasi https pada debian 7Konfigurasi https pada debian 7
Konfigurasi https pada debian 7CyberSpace
 
Panduan instalasi setiadi2 di server ubuntu 16.04
Panduan instalasi setiadi2 di server ubuntu 16.04Panduan instalasi setiadi2 di server ubuntu 16.04
Panduan instalasi setiadi2 di server ubuntu 16.04Dwi Fajar Saputra
 
cara install nginx dengan php5 dan dukungan Mysql Di CentOS 6.5
cara install nginx dengan php5 dan dukungan Mysql Di CentOS 6.5cara install nginx dengan php5 dan dukungan Mysql Di CentOS 6.5
cara install nginx dengan php5 dan dukungan Mysql Di CentOS 6.5stephan EL'wiin Shaarawy
 
Tubes streaming arc
Tubes streaming arcTubes streaming arc
Tubes streaming arcdianulhaq
 
Konfigurasi router debian 7
Konfigurasi router debian 7Konfigurasi router debian 7
Konfigurasi router debian 7sup4di
 
Tugas ke 2 sistem operasi ii
Tugas ke 2 sistem operasi iiTugas ke 2 sistem operasi ii
Tugas ke 2 sistem operasi iiRisna Risna
 
L6 web server_fadlysatriyagunawan
L6 web server_fadlysatriyagunawanL6 web server_fadlysatriyagunawan
L6 web server_fadlysatriyagunawanSMKN 1 Cimahi
 
Tugas pw [21] web server - fix
Tugas pw [21] web server - fixTugas pw [21] web server - fix
Tugas pw [21] web server - fixkwonnie
 
2013-39. Install Sistem Operasi melalui jaringan dengan ubuntu 10
2013-39. Install Sistem Operasi melalui jaringan dengan ubuntu 102013-39. Install Sistem Operasi melalui jaringan dengan ubuntu 10
2013-39. Install Sistem Operasi melalui jaringan dengan ubuntu 10Syiroy Uddin
 
2013-44. Install Sistem Operasi melalui jaringan dengan ubuntu 10
2013-44. Install Sistem Operasi melalui jaringan dengan ubuntu 102013-44. Install Sistem Operasi melalui jaringan dengan ubuntu 10
2013-44. Install Sistem Operasi melalui jaringan dengan ubuntu 10Syiroy Uddin
 
Router dan proxy server di debian 5
Router dan proxy server di debian 5Router dan proxy server di debian 5
Router dan proxy server di debian 5Hendi Alfiandi
 
Perkembangan web server
Perkembangan web server Perkembangan web server
Perkembangan web server fatek
 
3.1 lab-instalasi dan konfigurasi webserver-mysql-php-phpmyadmin
3.1 lab-instalasi dan konfigurasi webserver-mysql-php-phpmyadmin3.1 lab-instalasi dan konfigurasi webserver-mysql-php-phpmyadmin
3.1 lab-instalasi dan konfigurasi webserver-mysql-php-phpmyadminwayan abyong
 
Supriyanto squidproxyserver
Supriyanto squidproxyserverSupriyanto squidproxyserver
Supriyanto squidproxyserverHARRY CHAN PUTRA
 

Mais procurados (18)

TugasII SO2 Install Apache, PHP Dan MySQL Pada CentOS 7 (LAMP)
TugasII SO2 Install Apache, PHP Dan MySQL Pada CentOS 7 (LAMP)TugasII SO2 Install Apache, PHP Dan MySQL Pada CentOS 7 (LAMP)
TugasII SO2 Install Apache, PHP Dan MySQL Pada CentOS 7 (LAMP)
 
Cara Mengamankan Server OJS
Cara Mengamankan Server OJSCara Mengamankan Server OJS
Cara Mengamankan Server OJS
 
Konfigurasi https pada debian 7
Konfigurasi https pada debian 7Konfigurasi https pada debian 7
Konfigurasi https pada debian 7
 
FreeBSD Web Server
FreeBSD Web ServerFreeBSD Web Server
FreeBSD Web Server
 
Panduan instalasi setiadi2 di server ubuntu 16.04
Panduan instalasi setiadi2 di server ubuntu 16.04Panduan instalasi setiadi2 di server ubuntu 16.04
Panduan instalasi setiadi2 di server ubuntu 16.04
 
cara install nginx dengan php5 dan dukungan Mysql Di CentOS 6.5
cara install nginx dengan php5 dan dukungan Mysql Di CentOS 6.5cara install nginx dengan php5 dan dukungan Mysql Di CentOS 6.5
cara install nginx dengan php5 dan dukungan Mysql Di CentOS 6.5
 
Tubes streaming arc
Tubes streaming arcTubes streaming arc
Tubes streaming arc
 
Instalasi Upgrade Open Journal System
Instalasi Upgrade Open Journal SystemInstalasi Upgrade Open Journal System
Instalasi Upgrade Open Journal System
 
Konfigurasi router debian 7
Konfigurasi router debian 7Konfigurasi router debian 7
Konfigurasi router debian 7
 
Tugas ke 2 sistem operasi ii
Tugas ke 2 sistem operasi iiTugas ke 2 sistem operasi ii
Tugas ke 2 sistem operasi ii
 
L6 web server_fadlysatriyagunawan
L6 web server_fadlysatriyagunawanL6 web server_fadlysatriyagunawan
L6 web server_fadlysatriyagunawan
 
Tugas pw [21] web server - fix
Tugas pw [21] web server - fixTugas pw [21] web server - fix
Tugas pw [21] web server - fix
 
2013-39. Install Sistem Operasi melalui jaringan dengan ubuntu 10
2013-39. Install Sistem Operasi melalui jaringan dengan ubuntu 102013-39. Install Sistem Operasi melalui jaringan dengan ubuntu 10
2013-39. Install Sistem Operasi melalui jaringan dengan ubuntu 10
 
2013-44. Install Sistem Operasi melalui jaringan dengan ubuntu 10
2013-44. Install Sistem Operasi melalui jaringan dengan ubuntu 102013-44. Install Sistem Operasi melalui jaringan dengan ubuntu 10
2013-44. Install Sistem Operasi melalui jaringan dengan ubuntu 10
 
Router dan proxy server di debian 5
Router dan proxy server di debian 5Router dan proxy server di debian 5
Router dan proxy server di debian 5
 
Perkembangan web server
Perkembangan web server Perkembangan web server
Perkembangan web server
 
3.1 lab-instalasi dan konfigurasi webserver-mysql-php-phpmyadmin
3.1 lab-instalasi dan konfigurasi webserver-mysql-php-phpmyadmin3.1 lab-instalasi dan konfigurasi webserver-mysql-php-phpmyadmin
3.1 lab-instalasi dan konfigurasi webserver-mysql-php-phpmyadmin
 
Supriyanto squidproxyserver
Supriyanto squidproxyserverSupriyanto squidproxyserver
Supriyanto squidproxyserver
 

Destaque

CAHs Using Health Information Technology
CAHs Using Health Information TechnologyCAHs Using Health Information Technology
CAHs Using Health Information Technologywebhostingguy
 
Web Server(Apache),
Web Server(Apache), Web Server(Apache),
Web Server(Apache), webhostingguy
 
Application Note APLX-LMW-0403: Interfacing the Apache Web ...
Application Note APLX-LMW-0403: Interfacing the Apache Web ...Application Note APLX-LMW-0403: Interfacing the Apache Web ...
Application Note APLX-LMW-0403: Interfacing the Apache Web ...webhostingguy
 
Super Committee To The Rescue
Super Committee To The RescueSuper Committee To The Rescue
Super Committee To The RescueJeff Green
 
Detecting Typo-squatting Domains Mishari Almishari
Detecting Typo-squatting Domains Mishari AlmishariDetecting Typo-squatting Domains Mishari Almishari
Detecting Typo-squatting Domains Mishari Almishariwebhostingguy
 
PowerPoint Presentation
PowerPoint PresentationPowerPoint Presentation
PowerPoint Presentationwebhostingguy
 
Web Packages...Internet Marketing....Hosting
Web Packages...Internet Marketing....Hosting Web Packages...Internet Marketing....Hosting
Web Packages...Internet Marketing....Hosting webhostingguy
 

Destaque (8)

CAHs Using Health Information Technology
CAHs Using Health Information TechnologyCAHs Using Health Information Technology
CAHs Using Health Information Technology
 
Web Server(Apache),
Web Server(Apache), Web Server(Apache),
Web Server(Apache),
 
Application Note APLX-LMW-0403: Interfacing the Apache Web ...
Application Note APLX-LMW-0403: Interfacing the Apache Web ...Application Note APLX-LMW-0403: Interfacing the Apache Web ...
Application Note APLX-LMW-0403: Interfacing the Apache Web ...
 
Super Committee To The Rescue
Super Committee To The RescueSuper Committee To The Rescue
Super Committee To The Rescue
 
Detecting Typo-squatting Domains Mishari Almishari
Detecting Typo-squatting Domains Mishari AlmishariDetecting Typo-squatting Domains Mishari Almishari
Detecting Typo-squatting Domains Mishari Almishari
 
PowerPoint Presentation
PowerPoint PresentationPowerPoint Presentation
PowerPoint Presentation
 
Web Packages...Internet Marketing....Hosting
Web Packages...Internet Marketing....Hosting Web Packages...Internet Marketing....Hosting
Web Packages...Internet Marketing....Hosting
 
cPanel User Manual
cPanel User ManualcPanel User Manual
cPanel User Manual
 

Semelhante a websecure.ppt

Perkembangan web server di linux
Perkembangan web server di linuxPerkembangan web server di linux
Perkembangan web server di linuxNursaniATakome
 
Tutorial Instalasi TKJ CLoud Server
Tutorial Instalasi TKJ CLoud ServerTutorial Instalasi TKJ CLoud Server
Tutorial Instalasi TKJ CLoud ServerKurniawan Suganda
 
Integrasi slims atau eprints dengan dspace
Integrasi slims atau eprints dengan dspaceIntegrasi slims atau eprints dengan dspace
Integrasi slims atau eprints dengan dspaceDwi Fajar Saputra
 
Perkembangan web server di Linux
Perkembangan web server di LinuxPerkembangan web server di Linux
Perkembangan web server di LinuxTugas_SO2
 
3.1 lab-instalasi dan konfigurasi webserver-mysql-php-phpmyadmin
3.1 lab-instalasi dan konfigurasi webserver-mysql-php-phpmyadmin3.1 lab-instalasi dan konfigurasi webserver-mysql-php-phpmyadmin
3.1 lab-instalasi dan konfigurasi webserver-mysql-php-phpmyadminwayan abyong
 
14001326 all-about-squid-apache - [the-xp.blogspot.com]
14001326 all-about-squid-apache - [the-xp.blogspot.com]14001326 all-about-squid-apache - [the-xp.blogspot.com]
14001326 all-about-squid-apache - [the-xp.blogspot.com]Krisman Tarigan
 
Apache web server 1
Apache web server 1Apache web server 1
Apache web server 1Ali Muntaha
 
Multiple webserver in single ip with Haproxy & Mikrotik
Multiple webserver in single ip with Haproxy & MikrotikMultiple webserver in single ip with Haproxy & Mikrotik
Multiple webserver in single ip with Haproxy & Mikrotiktaufiknurhuda
 
konfigurasi web server
konfigurasi web serverkonfigurasi web server
konfigurasi web serverMuhammad Anang
 

Semelhante a websecure.ppt (20)

websecure.ppt
websecure.pptwebsecure.ppt
websecure.ppt
 
Perkembangan web server di linux
Perkembangan web server di linuxPerkembangan web server di linux
Perkembangan web server di linux
 
Tutorial Instalasi TKJ CLoud Server
Tutorial Instalasi TKJ CLoud ServerTutorial Instalasi TKJ CLoud Server
Tutorial Instalasi TKJ CLoud Server
 
Web server HTTP dan HTTPS
Web server HTTP dan HTTPSWeb server HTTP dan HTTPS
Web server HTTP dan HTTPS
 
Konfigurasi web server
Konfigurasi web serverKonfigurasi web server
Konfigurasi web server
 
Presentasi (2).pptx
Presentasi (2).pptxPresentasi (2).pptx
Presentasi (2).pptx
 
Integrasi slims atau eprints dengan dspace
Integrasi slims atau eprints dengan dspaceIntegrasi slims atau eprints dengan dspace
Integrasi slims atau eprints dengan dspace
 
Perkembangan web server di Linux
Perkembangan web server di LinuxPerkembangan web server di Linux
Perkembangan web server di Linux
 
Sejarah web server
Sejarah web serverSejarah web server
Sejarah web server
 
Squid apache
Squid apacheSquid apache
Squid apache
 
3.1 lab-instalasi dan konfigurasi webserver-mysql-php-phpmyadmin
3.1 lab-instalasi dan konfigurasi webserver-mysql-php-phpmyadmin3.1 lab-instalasi dan konfigurasi webserver-mysql-php-phpmyadmin
3.1 lab-instalasi dan konfigurasi webserver-mysql-php-phpmyadmin
 
14001326 all-about-squid-apache - [the-xp.blogspot.com]
14001326 all-about-squid-apache - [the-xp.blogspot.com]14001326 all-about-squid-apache - [the-xp.blogspot.com]
14001326 all-about-squid-apache - [the-xp.blogspot.com]
 
Web server
Web serverWeb server
Web server
 
Workshop & pelatihan
Workshop & pelatihanWorkshop & pelatihan
Workshop & pelatihan
 
Nutch dan Solr
Nutch dan SolrNutch dan Solr
Nutch dan Solr
 
Apache web server 1
Apache web server 1Apache web server 1
Apache web server 1
 
Tugas Pw [21]
Tugas Pw [21]Tugas Pw [21]
Tugas Pw [21]
 
Web server mjs
Web server mjsWeb server mjs
Web server mjs
 
Multiple webserver in single ip with Haproxy & Mikrotik
Multiple webserver in single ip with Haproxy & MikrotikMultiple webserver in single ip with Haproxy & Mikrotik
Multiple webserver in single ip with Haproxy & Mikrotik
 
konfigurasi web server
konfigurasi web serverkonfigurasi web server
konfigurasi web server
 

Mais de webhostingguy

Running and Developing Tests with the Apache::Test Framework
Running and Developing Tests with the Apache::Test FrameworkRunning and Developing Tests with the Apache::Test Framework
Running and Developing Tests with the Apache::Test Frameworkwebhostingguy
 
MySQL and memcached Guide
MySQL and memcached GuideMySQL and memcached Guide
MySQL and memcached Guidewebhostingguy
 
Novell® iChain® 2.3
Novell® iChain® 2.3Novell® iChain® 2.3
Novell® iChain® 2.3webhostingguy
 
Load-balancing web servers Load-balancing web servers
Load-balancing web servers Load-balancing web serversLoad-balancing web servers Load-balancing web servers
Load-balancing web servers Load-balancing web serverswebhostingguy
 
SQL Server 2008 Consolidation
SQL Server 2008 ConsolidationSQL Server 2008 Consolidation
SQL Server 2008 Consolidationwebhostingguy
 
Master Service Agreement
Master Service AgreementMaster Service Agreement
Master Service Agreementwebhostingguy
 
PHP and MySQL PHP Written as a set of CGI binaries in C in ...
PHP and MySQL PHP Written as a set of CGI binaries in C in ...PHP and MySQL PHP Written as a set of CGI binaries in C in ...
PHP and MySQL PHP Written as a set of CGI binaries in C in ...webhostingguy
 
Dell Reference Architecture Guide Deploying Microsoft® SQL ...
Dell Reference Architecture Guide Deploying Microsoft® SQL ...Dell Reference Architecture Guide Deploying Microsoft® SQL ...
Dell Reference Architecture Guide Deploying Microsoft® SQL ...webhostingguy
 
Managing Diverse IT Infrastructure
Managing Diverse IT InfrastructureManaging Diverse IT Infrastructure
Managing Diverse IT Infrastructurewebhostingguy
 
Web design for business.ppt
Web design for business.pptWeb design for business.ppt
Web design for business.pptwebhostingguy
 
IT Power Management Strategy
IT Power Management Strategy IT Power Management Strategy
IT Power Management Strategy webhostingguy
 
Excel and SQL Quick Tricks for Merchandisers
Excel and SQL Quick Tricks for MerchandisersExcel and SQL Quick Tricks for Merchandisers
Excel and SQL Quick Tricks for Merchandiserswebhostingguy
 
Parallels Hosting Products
Parallels Hosting ProductsParallels Hosting Products
Parallels Hosting Productswebhostingguy
 
Microsoft PowerPoint presentation 2.175 Mb
Microsoft PowerPoint presentation 2.175 MbMicrosoft PowerPoint presentation 2.175 Mb
Microsoft PowerPoint presentation 2.175 Mbwebhostingguy
 

Mais de webhostingguy (20)

File Upload
File UploadFile Upload
File Upload
 
Running and Developing Tests with the Apache::Test Framework
Running and Developing Tests with the Apache::Test FrameworkRunning and Developing Tests with the Apache::Test Framework
Running and Developing Tests with the Apache::Test Framework
 
MySQL and memcached Guide
MySQL and memcached GuideMySQL and memcached Guide
MySQL and memcached Guide
 
Novell® iChain® 2.3
Novell® iChain® 2.3Novell® iChain® 2.3
Novell® iChain® 2.3
 
Load-balancing web servers Load-balancing web servers
Load-balancing web servers Load-balancing web serversLoad-balancing web servers Load-balancing web servers
Load-balancing web servers Load-balancing web servers
 
SQL Server 2008 Consolidation
SQL Server 2008 ConsolidationSQL Server 2008 Consolidation
SQL Server 2008 Consolidation
 
What is mod_perl?
What is mod_perl?What is mod_perl?
What is mod_perl?
 
What is mod_perl?
What is mod_perl?What is mod_perl?
What is mod_perl?
 
Master Service Agreement
Master Service AgreementMaster Service Agreement
Master Service Agreement
 
Notes8
Notes8Notes8
Notes8
 
PHP and MySQL PHP Written as a set of CGI binaries in C in ...
PHP and MySQL PHP Written as a set of CGI binaries in C in ...PHP and MySQL PHP Written as a set of CGI binaries in C in ...
PHP and MySQL PHP Written as a set of CGI binaries in C in ...
 
Dell Reference Architecture Guide Deploying Microsoft® SQL ...
Dell Reference Architecture Guide Deploying Microsoft® SQL ...Dell Reference Architecture Guide Deploying Microsoft® SQL ...
Dell Reference Architecture Guide Deploying Microsoft® SQL ...
 
Managing Diverse IT Infrastructure
Managing Diverse IT InfrastructureManaging Diverse IT Infrastructure
Managing Diverse IT Infrastructure
 
Web design for business.ppt
Web design for business.pptWeb design for business.ppt
Web design for business.ppt
 
IT Power Management Strategy
IT Power Management Strategy IT Power Management Strategy
IT Power Management Strategy
 
Excel and SQL Quick Tricks for Merchandisers
Excel and SQL Quick Tricks for MerchandisersExcel and SQL Quick Tricks for Merchandisers
Excel and SQL Quick Tricks for Merchandisers
 
OLUG_xen.ppt
OLUG_xen.pptOLUG_xen.ppt
OLUG_xen.ppt
 
Parallels Hosting Products
Parallels Hosting ProductsParallels Hosting Products
Parallels Hosting Products
 
Microsoft PowerPoint presentation 2.175 Mb
Microsoft PowerPoint presentation 2.175 MbMicrosoft PowerPoint presentation 2.175 Mb
Microsoft PowerPoint presentation 2.175 Mb
 
Reseller's Guide
Reseller's GuideReseller's Guide
Reseller's Guide
 

websecure.ppt

  • 1. APACHE 2 Secure HTTP With Apache Web Server By GOODLE CREW
  • 2. Web Server  Adalah suatu daemon yang berfungsi menerima request melalui protocol http baik dari local maupun dari internet  Informasi yang direquest oleh web browser bisa berupa file yang ada dalam storage atau meminta server untuk melakukan funsgi tertentu
  • 3.  IIS (web server untuk html & asp ).Bisa jalan di OS Windows  APACHE webserver (web server untuk html,php,asp,jsp, dsb).Bisa jalan di OS Windows dan LINUX. Sifatnya modular dengan ditambahkan libapache2 Macam Web Server
  • 4.  HTTPS adalah varian dari protocol HTTP dimana user mengakses dengan https://  Data yang dikirim ke server adalah data yang terenkripsi.  Enkripsi yang digunakan adalah enkripsi SSL (Secure socket Layer).  Menggunakan TCP port 443. APACHE Web Server dengan HTTPS
  • 6.  Install apache2 dan modul PHP4 • # apt-get install apache2 php4 libapache2-mod- php4  Buat Duplikat dari file: /etc/apache2/sites-available/default • # cp /etc/apache2/sites-available/default /etc/apache2/sites-available/website-ssl  Buat link untuk mengaktifkan modul ssl saat apache di load • # a2ensite • Masukkan “website-ssl” Mengkonfigurasi HTTPS
  • 7. Mengkonfigurasi HTTPS  Mengaktifkan modul php4 • a2enmod • dijawab dengan “php4”  mengaktifkan modul ssl • a2enmod • dijawab dengan “ssl”
  • 8.  Kemudian Edit • /etc/apache2/sites-enabled/website-ssl NameVirtualHost *:443 <VirtualHost *:443> SSLEngine On SSLCertificateFile /etc/apache2/ssl/apache.pem ... </VirtualHost> Mengkonfigurasi HTTPS
  • 9.  Generate Sertifikat anda sendiri dengan • # apache2-ssl-certificate • kalo apache2-ssl-certificate tidak ada gunakan : • # mkdir /etc/apache2/ssl • # openssl req $@ -new -x509 -days 365 -nodes -out /etc/apache2/ssl/apache.pem -keyout /etc/apache2/ssl/apache.pem • Kemudian anda akan diminta memasukkan kode negara(ID),State atau propinsi,Nama Kota,Company,Section Unit,Domain,alamat email Membuat Sertikat SSL
  • 10.  Menambahkan Port Listen Untuk SSL,untuk melakukanya edit file: • /etc/apache2/ports.conf  Tambahkan Baris : • Listen 443 Mengkonfigurasi HTTPS
  • 11.  Restart APACHE2 • /etc/init.d/apache2 restart Mengkonfigurasi HTTPS
  • 12.  Buka web browser  Cobalah ketikkan https://localhost/ Mencoba Setting HTTPS
  • 16. Mengkonfigurasi mod-security  Mod-security ??? • Bagaimana cara anda untuk membatasi SQL injection, mendefinisikan hanya satu web browser saja yg boleh akses, jumlah data, dll... --> membatasi lewat aplikasi • Apache2 menyediakan modul • libapache2-mod-security
  • 17. Mengkonfigurasi mod-security  Install : • # apt-get install libapache2-mod-security  Mengaktifkan module • a2enmod • isi dengan “mod-security”
  • 18. Mengkonfigurasi mod-security  Copy contoh konfigurasi • # cd /etc/apache2/conf.d • # cp /usr/share/doc/libapache2-mod- security/examples/httpd2.conf.example-full mod-security.conf  Restart apache • # /etc/init.d/apache2 restart
  • 19. Uji Coba mod-security  Jalankan aplikasi testingnya • # cd /usr/share/mod-security/test/ • # ./run-test.pl localhost *.test  Buka website dengan webbrowser “w3m” dan mozilla • # w3m http://localhost • akan terjawab IIS ... lo bukannya tadi install apache2 ???
  • 21. Chroot  chroot – change root directory • dir /var/www/ berubah seolah- olah menjadi dir “/”  apache2 jalan di chroot
  • 22. Mengkonfigurasi mod-chroot  Install module chroot • # apt-get install libapache2-mod-chroot  Aktifkan module chroot • # a2enmod • isi dengan “mod_chroot”
  • 23. Mengkonfigurasi mod-chroot  Buat konfigurasi untuk mod-chroot, bisa di /etc/apache2/conf.d • # cd /etc/apache2/conf.d • vim mod-chroot <IfModule mod_chroot.c> LoadFile /lib/libgcc_s.so.1 </IfModule> ChrootDir /var/www
  • 24. Mengkonfigurasikan mod-chroot  Buat dir untuk chroot • # mkdir -p /var/www/var/run  Jalankan apache2 • # /etc/init.d/apache2 start  Rubah pidfile • # cd /var/run • # ln -s /var/www/var/run/apache2.pid apache2.pid
  • 25. Mengkonfigurasi mod-chroot  buat file coba.php <? system(“ls /etc”); ?>  Script php untuk melihat isi dir /etc  Bandingkan hasilnya antara ada mod- chroot dan tidak menggunakan mod- chroot