Anda di halaman 1dari 31

Network Security

Intrusion Detection System


(Portsentry dan Honeypot)
Muhammad Zen S. Hadi

N t
Network
k IIntrusion
t i Detection
D t ti

Memahasi dasar intrusion detection systems (portsentry)


Memahami dasar honeypot

Fi
Firewall
ll S
Saja
j Tdk C
Cukup
k

Tidak semua akses melalui firewall


Ada beberapa aplikasi yang memang diloloskan
oleh
l h fi
firewallll (W
(Web,
b E
Email,
il dll)
Tidak semua ancaman berasal dari luar firewall,
tapi dari dalam jaringan sendiri
Firewall kadang merupakan object serangan
Perlu suatu aplikasi sebagai pelengkap Firewall
yang bisa mendeteksi ancaman yang tidak bisa
diproteksi oleh firewall
3

D S preventive
DoS
ti

IDS
IPS
Honeypots
firewall

I t i Detection
Intrusion
D t ti System
S t
(IDS)

Examining system logs (host based)


Examining network traffic (network based)
A Combination of the two
Implementation:

snort

I t i Prevention
Intrusion
P
ti System
S t
(IPS)

Upgrade application
Active reaction (IDS = passive)
Implementation:

portsentry

P
Pengertian
ti IDS

IDS kepanjangan Intrusion Detection System


Sistem untuk mendeteksi dan merespons adanya
intrusion
intrusion yang dilakukan oleh intruder
intruder
Pendeteksian bisa dilakukan sebelum, selama dan
sesudah kejadian.

Terdeteksi
T
d k i sebelum,
b l
maka
k bi
bisa melakukan
l k k tindakan
i d k
pencegahan
Terdeteksi selama : bisa diputuskan untuk diblok dan alarm
Terdeteksi
T d t k i setelah
t l h : melihat
lih t akibat
kib t yang ditimbulkan
diti b lk

IDS mengumpulkan info dari dari berbagai sistem dan


source network kemudian melakukan analisa terhadap
i f tsb
info
b sesuaii d
dengan rule
l yang sudah
d h di
ditetapkan
k
7

P
Pengertian
ti IDS (C
(Cont)
t )

Intrusion

Didefinisikan sebagai kegiatan yang bersifat anomaly, incorrect,


inappropriate yang terjadi di jaringan atau di host
Klasifikasi intrusi :

Attempted Break-ins
Masquerade attacks
Penetration of Security Control Systems
Leakage
Denial of Service
Malicious Use

Anomaly merupakan Traffic/aktivitas yang tidak sesuai


d policy:
dgn
li

akses dari/ke host yang terlarang


memiliki content terlarang (virus)
menjalankan program terlarang (web directory traversal:GET
../..;cmd.exe )
8

I t i Detection
Intrusion
D t ti System
S t
(IDS)

Intrusion detection adalah proses notifikasi ketika


seseorang ingin masuk ke sebuah sistem.
K t
Kategori
i dari
d i software
ft
ini
i i disebut
di b t iintrusion
t i d
detection
t ti
systems (IDS)
PortSentry, oleh Psionic, melihat port network ketika
paket melakukan port scan.
Tool yang lebih kompleks dari PortSentry adalah Linux
IDS atau
IDS,
t LIDS
LIDS, yang d
dapatt merubah
b h Li
Linux kkernell

Penggunaan Software Intrusion


Detection

Penggunaan yang disarankan untuk tool intrusion


detection :

Gunakan nmap untuk scan system setelah konfigurasi untuk


mengecek security holes.
Selanjutnya, gunakan PortSentry untuk melihat host luar yang
mencoba melakukan port scan ke server
server.
Gunakan LIDS untuk mengamankan file system anda, sehingga
seseorang yang ingin untuk masuk ke server akan mempunyai
akses yang dibatasi
dibatasi.

10

B i IIntrusion
Basic
t i D
Detection
t ti
Target
y
System

Respond

Monitor Intrusion
Detection
System
Report

Intrusion Detection System Infrastructure

11

I t i Detection
Intrusion
D t ti System
S t
IDS

Port : Pelabuhan
Sentry : Penjaga
P S
PortSentry
adalah
d l h sebuah
b h perangkat
k llunak
k yang di
rancang untuk mendeteksi adanya port scanning &
meresponds
p
secara aktif jjika ada p
port scanning
g secara
real time

portsentry mencegah portscan

Jalankan sebagai daemon pada host yang terproteksi, hal ini


akan mendengarkan ke port TCP/UDP dan akan memblok
g host dari server yyang
g terkoneksi.
scanning

Untuk implementasi : http://sourceforge.net/projects/sentrytools/


12

PortSentry
P
tS t
http://www.psionic.com/products/portsentry.html.

13

Pl tf
Platform
Port
P t Sentry
S t

FreeBSD
Open BSD
Linux

14

K
Keuntungan
t
Port
P t Sentry
S t
Deteksi

portscan TCP/UDP berbasis hostbased dan mengaktifkan sistem pertahanan


Deteksi Stealth scan
Bereaksi ke portscan dengan memblok host
Internal state engine untuk mengingat host
yang terkoneksi sebelumnya
Semua kejadian akan disimpan ke syslog

15

K k
Kekurangan
Port
P t Sentry
S t

Portsentry dibinding ke port sehingga diperlukan


pengecekan menyeluruh
Tid k dapat
Tidak
d
t mendeteksi
d t k i spoofing
fi

16

Di
Dimana
P
Portt S
Sentry
t Dil
Diletakkan
t kk

Dibelakang Firewall
Dibelakang tiap host yang dilindungi

17

EEPIS Secure Network

18

Fit
Fiture
PortSentry
P tS t

Mendeteksi scan
Melakukan aksi terhadap host yg melakukan pelanggaran
Mengemail admin system bila di integrasikan dengan
Logcheck/LogSentry

19

Ak i yang dil
Aksi
dilakukan
k k P
Portt S
Sentry
t

Stealth setting
g ????
Melogging semua pelanggaran di syslog dan
mengindikasikan nama system, waktu serangan, IP mesin
penyerang, TCP / UDP portt tempat
t
t serangan dilakukan.
dil k k
Menambahkan entry untuk penyerang di /etc/hosts.deny
Mengeblok akses ke sistem berbasis iptables atau
tcpwrapper

20

Fil K
File
Konfigurasi
fi
iP
PortSentry
tS t

fil //etc/portsentry/portsentry.conf
file
t / t
t / t
t
f
merupakan konfigurasi utama portsentry. Disini secara bertahap
diset port mana saja yang perlu di monitor, responds apa yang
harus di lakukan ke mesin yang melakukan portscan, mekanisme
menghilangkan mesin dari routing table, masukan ke host.deny.

file /etc/default/portsentry
p
y

set mode deteksi yang dilakukan portsentry.


Semakin baik mode deteksi yang dipilih (advanced stealth
TCP/UP scanning),
scanning) biasanya PortSentry akan semakin sensitif &
semakin rewel karena sedikit-sedikit akan memblokir mesin.

file /etc/portsentry/portsentry.ignore
i ik IP address
isikan
dd
yang perlu
l di abaikan
b ik
21

M j l k portsentry
Menjalankan
t
t

/usr/sbin/portsentry
/etc/init.d/portsentry start
portsentry -udp
udp (normal scan detection)
portsentry -tcp (normal scan detection)
portsentry
p
y -sudp
p ((normal stealth scan detection))
portsentry -stcp (normal stealth scan detection)
portsentry -audp (advanced stealth scan detection)
portsentry
t
t -atcp
t (advanced
( d
d stealth
t lth scan d
detection)
t ti )

22

K fi
Konfigurasi
iP
Portt S
Sentry
t

Un-comment these if you are really anal:


#TCP PORTS="1 7 9 11 15 70 79 80 109 110 111 119 138 139 143 5
#TCP_PORTS="1,7,9,11,15,70,79,80,109,110,111,119,138,139,143,5
12,513,514,515,540,635,1080,1524,2000,2001,[..]
#UDP_PORTS="1,7,9,66,67,68,69,111,137,138,161,162,474,513,517,
518,635,640,641,666,700,2049,31335,27444,34555,[..]
##U
Use th
these if you jjustt wantt tto b
be aware:
TCP_PORTS="1,11,15,79,111,119,143,540,635,1080,1524,2000,5742
,6667,12345,12346,20034,27665,31337,32771,32772,[..]
UDP_PORTS="1,7,9,69,161,162,513,635,640,641,700,37444,34555,3
1335 32770 32771 32772 32773 32774 31337 54321
1335,32770,32771,32772,32773,32774,31337,54321
# # Use these for just bare-bones
#TCP_PORTS="1,11,15,110,111,143,540,635,1080,1524,2000,12345,
,
,
,
,
,
,
,
12346,20034,32771,32772,32773,32774,49724,54320"
#UDP_PORTS="1,7,9,69,161,162,513,640,700,32770,32771,32772,3
2773,32774,31337,54321"

23

Bl ki H
Blocking
Hostt

file /etc/portsentry/portsentry.conf
Blocking dengan iptables :
KILL_ROUTE="/usr/local/sbin/iptables -I INPUT -s
$TARGET$ -j DROP
Blocking dengan tcpwrapper :
KILL_HOSTS_DENY="ALL: $TARGET$ : DENY"

24

D ft Log
Daftar
L S
Serangan

/etc/hosts.deny
/etc/portsentry/portsentry.blocked.atcp
/etc/portsentry/portsentry.blocked.audp
/etc/portsentry/portsentry.history

25

O t t PortSentry
Output
P tS t

Sep 19 01:50:19 striker portsentry[129]:


attackalert: \ Host 192.168.0.1 has been blocked
via dropped route using command: \ "/sbin/ipfw
add 1 deny all from
192 168 0 1:255 255 255 255 to any"
192.168.0.1:255.255.255.255
any
Sep 19 01:50:19 striker portsentry[129]:
attackalert: \ Connect from host:
192.168.0.1/192.168.0.1 to TCP port: 9 Sep 19
01:50:19
0
50 9 sstriker
e po
portsentry[129]:
se y[ 9] a
attackalert:
ac a e \
Host: 192.168.0.1 is already blocked. Ignoring
26

H
Honeypot
t

Merupakan sebuah resource yang berpura-pura menjadi


sebuah target real, yang diharapkan untuk diserang.
T j
Tujuan
utamanya
t
:

membelokkan attacker dari serangan ke productive system


mendapatkan
p
informasi tentang
g jjenis-jenis
j
serangan
g dan
penyerang.

Penempatan honeypot

Penempatan secara tidak langsung antara firewall dan internet


Penempatan honeypot pada DMZ

27

Honeypots
(http://www.honeynet.org)

28

Vi t l H
Virtual
Honeynett

Implement

I t
Internet
t

VMware

Host Operating System

Guest OS Guest OS Guest OS

29

Ti Honeypot
Tipe
H
t

High
Hi
h IInteraction
t
ti H
Honeypott
adalah sistem yang mengoperasikan Sistem Operasi
penuh sehingga penyerang akan melihatnya sebagai
sebuah sistem operasi/host yang siap untuk dieksploitasi
Low Interaction Honeypot
mensimulasikan sebuah sistem operasi dengan serviceservice tertentu(misalnya SSH,HTTP,FTP) atau dengan
kata lain sistem yang bukan merupakan sistem operasi
secara keseluruhan, service yang berjalan tidak bisa
dieksploitasi untuk mendapatkan akses penuh terhadap
h
honeypot.
t
30

T j
Tujuan
H
Honeypott

Early Detection
Pendeteksian ancaman baru
Mengenal si attacker (know your enemy)
Menyelamatkan sistem
M
Mengacaukan
k pola
l fiki
fikir attacker
tt k
Membangun pertahanan
Mencegah proses hacking

31

Anda mungkin juga menyukai