Python console double enter doesn't work everytime to start the loop -
after loop done use double enter start it. works example:
>>> in range(0,100): ... print
but can't double enter when comes 1 (a code sample studying pentesting.). starts new line no triple dots.
>>> import socket >>> sniff = socket.socket(socket.af_packet, socket.sock_raw, 3) >>> sniff.bind(("eth0", 0x0003)) >>> ap_list =[] >>> while true : ... fm = sniff.recvfrom(6000) ... fm= fm1[0] ... if fm[26] == "\x80" : ... if fm[36:42] not in ap_list: ... ap_list.append(fm[36:42]) ... = ord(fm[63]) ... print "ssid -> ",fm[64:64 +a],"-- bssid ->", \ ... fm[36:42].encode('hex'),"-- channel -> ", ord(fm[64 +a+12])
edit: i'm using linux(xubuntu 14.04).
Comments
Post a Comment