Ejemplo n.º 1
0
 def setUp(self):
     self.ip_str = ipv4(self.orig_ip_str)
     self.ip_list = ipv4(self.orig_ip_list)
     self.ip_int = ipv4(self.orig_ip_int)
Ejemplo n.º 2
0
 def setUp(self):
     self.ip_str = ipv4(self.orig_ip_str)
     self.ip_list = ipv4(self.orig_ip_list)
     self.ip_int = ipv4(self.orig_ip_int)
Ejemplo n.º 3
0
#!/usr/bin/python

from isdhcplib.dhcp_packet import DhcpPacket
from isdhcplib.type_strlist import strlist
from isdhcplib.type_ipv4 import ipv4

packet = DhcpPacket()

packet.SetOption("op", [1])
packet.SetOption("domain_name", list(strlist("anemon.org")))
packet.SetOption("router", list(ipv4("192.168.0.1")) + [6, 4, 2, 1])
packet.SetOption("time_server", [100, 100, 100, 7, 6, 4, 2, 1])
packet.SetOption("yiaddr", [192, 168, 0, 18])

print packet
Ejemplo n.º 4
0
#!/usr/bin/python

from isdhcplib.dhcp_packet import DhcpPacket
from isdhcplib.type_strlist import strlist
from isdhcplib.type_ipv4 import ipv4


packet = DhcpPacket()

packet.SetOption("op",[1])
packet.SetOption("domain_name", list(strlist("anemon.org")))
packet.SetOption("router",list(ipv4("192.168.0.1"))+[6,4,2,1])
packet.SetOption("time_server",[100,100,100,7,6,4,2,1])
packet.SetOption("yiaddr",[192,168,0,18])

print packet