![]() |
2010-10-18
, 18:06
|
|
Posts: 1,030 |
Thanked: 792 times |
Joined on Jun 2009
|
#2
|
![]() |
2010-10-18
, 19:44
|
Posts: 540 |
Thanked: 387 times |
Joined on May 2009
|
#3
|
![]() |
2010-10-18
, 20:31
|
Posts: 30 |
Thanked: 42 times |
Joined on Oct 2010
@ Russia
|
#4
|
#!/usr/bin/python import subprocess import sqlite3 import time def collect(): data = [] b = subprocess.Popen(['hcitool', 'scan'], stdout=subprocess.PIPE) x = b.communicate()[0] for l in x.splitlines()[1:]: l = l.strip().decode('utf8', 'replace') parts = l.split('\t', 1) mac, name = parts if len(parts)==2 else (l, '') data.append((mac, name)) return data conn = sqlite3.connect('bt.sqlite3') cur = conn.cursor() cur.execute('CREATE TABLE IF NOT EXISTS bt (date INTEGER, mac TEXT, name TEXT)') conn.commit() while 1: print 'collecting' devs = collect() for m,n in devs: print m, n t = int(time.time()) cur.executemany('INSERT INTO bt VALUES (?,?,?)', map(lambda (m,n): (t,m,n), devs)) conn.commit() time.sleep(10)
![]() |
2010-10-19
, 14:37
|
Posts: 393 |
Thanked: 67 times |
Joined on Feb 2010
|
#5
|
![]() |
2010-10-19
, 23:57
|
Posts: 2,225 |
Thanked: 3,822 times |
Joined on Jun 2010
@ Florida
|
#6
|
![]() |
2010-10-20
, 00:19
|
|
Posts: 1,030 |
Thanked: 792 times |
Joined on Jun 2009
|
#7
|
The Following User Says Thank You to hawaii For This Useful Post: | ||
![]() |
2010-10-20
, 02:01
|
Posts: 2,225 |
Thanked: 3,822 times |
Joined on Jun 2010
@ Florida
|
#8
|
![]() |
2010-10-20
, 04:25
|
Posts: 2,225 |
Thanked: 3,822 times |
Joined on Jun 2010
@ Florida
|
#10
|
Perhaps some interesting scripts related to networking or penetration testing. Are we free to use any stock shell or Python script on the N900, are the interpreters any different from the ones found on non-ARM (non-mobile) Linux distributions?
Thank you
Last edited by mail_e36; 2010-10-18 at 18:18.