Пример #1
0
def start():
    s = NonBlockingSniffer("en0", read_timeout=2000)
    s.filter = "udp and dst port 53"
    # s.set_loop(IOLoop.instance()).sniff_and_store(q, lambda buf: EthernetII(buf=buf))
    # s.set_loop(IOLoop.instance()).sniff_and_export('/Users/stef/baaaa2.pcap')
    s.set_loop(IOLoop.instance()).sniff_callback(callback)
Пример #2
0
def start():
    s = NonBlockingSniffer("en0", read_timeout=2000)
    s.filter = "udp and dst port 53"
    # s.set_loop(IOLoop.instance()).sniff_and_store(q, lambda buf: EthernetII(buf=buf))
    # s.set_loop(IOLoop.instance()).sniff_and_export('/Users/stef/baaaa2.pcap')
    s.set_loop(IOLoop.instance()).sniff_callback(callback)
Пример #3
0
def handle_int(signum, frame):
    global stopping
    NonBlockingSniffer.stop_all()
    stopping = True
    IOLoop.instance().stop()
Пример #4
0
def handle_int(signum, frame):
    global stopping
    NonBlockingSniffer.stop_all()
    stopping = True
    IOLoop.instance().stop()