[DHCP tools + random] Pour que tout marche mieux.
Ignore-this: 590aacb4887da39fd62052c13508c65b darcs-hash:20120808150616-b6762-4d571c82be02d5cdaa6f275d2518eddd0061a42f.gz
This commit is contained in:
parent
b311d40252
commit
b7a333074d
5 changed files with 20 additions and 7 deletions
|
@ -22,6 +22,9 @@ from locate_mac import trace_machine, info_machine
|
|||
|
||||
PIDFILE = "/var/run/dhcp-detect.pid"
|
||||
|
||||
# dhcp-server attendu
|
||||
DHCPSERVER = '138.231.136.9'
|
||||
|
||||
# Interface à surveiller
|
||||
INTERFACE = "crans"
|
||||
|
||||
|
@ -113,7 +116,7 @@ def recoit(paquet):
|
|||
# On affiche
|
||||
print "Réception de : ", paquet.summary()
|
||||
# On verifie que c'est bien ce qu'on attend
|
||||
if paquet.getlayer(Ether).dst.upper() == globals()['mac'] and paquet.haslayer(BOOTP) and paquet.getlayer(BOOTP).op == 2 and paquet.getlayer(IP).src != '138.231.136.39':
|
||||
if paquet.getlayer(Ether).dst.upper() == globals()['mac'] and paquet.haslayer(BOOTP) and paquet.getlayer(BOOTP).op == 2 and paquet.getlayer(IP).src != DHCPSERVER:
|
||||
# DHCP pirate ?
|
||||
msg = "DHCP pirate ? (%s)" % paquet.getlayer(Ether).src
|
||||
print msg
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue