Lines Matching refs:id

27     id = dev[0].add_network()
29 if "FAIL" not in dev[0].request("SET_NETWORK " + str(id)):
31 if "FAIL" not in dev[0].request("SET_NETWORK " + str(id) + " name"):
33 if "FAIL" not in dev[0].request("SET_NETWORK " + str(id + 1) + " proto OPEN"):
35 if "FAIL" not in dev[0].request("GET_NETWORK " + str(id)):
37 if "FAIL" not in dev[0].request("GET_NETWORK " + str(id + 1) + " proto"):
40 if "OK" not in dev[0].request("SET_NETWORK " + str(id) + " proto \t WPA2 "):
42 res = dev[0].request("GET_NETWORK " + str(id) + " proto")
46 if "OK" not in dev[0].request("SET_NETWORK " + str(id) + " key_mgmt \t WPA-PSK "):
48 res = dev[0].request("GET_NETWORK " + str(id) + " key_mgmt")
52 if "OK" not in dev[0].request("SET_NETWORK " + str(id) + " auth_alg \t OPEN "):
54 res = dev[0].request("GET_NETWORK " + str(id) + " auth_alg")
58 if "OK" not in dev[0].request("SET_NETWORK " + str(id) + " eap \t TLS "):
60 res = dev[0].request("GET_NETWORK " + str(id) + " eap")
66 if "FAIL" not in dev[0].request("SET_NETWORK " + str(id) + " " + t):
86 dev[0].set_network_quoted(id, "ssid", "test")
88 dev[0].set_network(id, field, value)
89 res = dev[0].get_network(id, field)
95 dev[0].set_network(id, "key_mgmt", value)
96 res = dev[0].get_network(id, "key_mgmt")
108 dev[0].set_network_quoted(id, field, value)
109 res = dev[0].get_network(id, field)
115 res = dev[0].get_network(id, field)
119 if dev[0].get_network(id, "password"):
121 dev[0].set_network_quoted(id, "password", "foo")
122 if dev[0].get_network(id, "password") != '*':
124 dev[0].set_network(id, "password", "hash:12345678901234567890123456789012")
125 if dev[0].get_network(id, "password") != '*':
127 dev[0].set_network(id, "password", "NULL")
128 if dev[0].get_network(id, "password"):
130 if "FAIL" not in dev[0].request("SET_NETWORK " + str(id) + " password hash:12"):
132 …if "FAIL" not in dev[0].request("SET_NETWORK " + str(id) + " password hash:123456789012345678x0123…
135 dev[0].set_network(id, "identity", "414243")
136 if dev[0].get_network(id, "identity") != '"ABC"':
139 dev[0].set_network(id, "identity", 'P"abc\ndef"')
140 if dev[0].get_network(id, "identity") != "6162630a646566":
143 if "FAIL" not in dev[0].request("SET_NETWORK " + str(id) + ' identity P"foo'):
146 if "FAIL" not in dev[0].request("SET_NETWORK " + str(id) + ' identity 12x3'):
151 … if "FAIL" in dev[0].request("SET_NETWORK " + str(id) + ' wep_key' + str(i) + ' aabbccddee'):
153 if dev[0].get_network(id, "wep_key" + str(i)) != '*':
156 …if "FAIL" in dev[0].request("SET_NETWORK " + str(id) + ' psk_list P2P-00:11:22:33:44:55-0123456789…
159 …if "FAIL" not in dev[0].request("SET_NETWORK " + str(id) + ' psk_list 00:11:x2:33:44:55-0123456789…
162 …if "FAIL" not in dev[0].request("SET_NETWORK " + str(id) + ' psk_list P2P-00:11:x2:33:44:55-012345…
165 …if "FAIL" not in dev[0].request("SET_NETWORK " + str(id) + ' psk_list P2P-00:11:22:33:44:55+012345…
168 …if "FAIL" not in dev[0].request("SET_NETWORK " + str(id) + ' psk_list P2P-00:11:22:33:44:55-012345…
171 …if "FAIL" not in dev[0].request("SET_NETWORK " + str(id) + ' psk_list P2P-00:11:22:33:44:55-012345…
174 if dev[0].get_network(id, "psk_list"):
179 dev[0].set_network(id, "ssid", "NULL")
183 …if "FAIL" not in dev[0].request('SET_NETWORK ' + str(id) + ' ssid "0123456789abcdef0123456789abcde…
185 if "FAIL" not in dev[0].request('SET_NETWORK ' + str(id) + ' scan_ssid qwerty'):
187 if "FAIL" not in dev[0].request('SET_NETWORK ' + str(id) + ' scan_ssid 2'):
189 if "FAIL" not in dev[0].request('SET_NETWORK ' + str(id) + ' psk 12345678'):
191 if "FAIL" not in dev[0].request('SET_NETWORK ' + str(id) + ' psk "1234567"'):
193 …if "FAIL" not in dev[0].request('SET_NETWORK ' + str(id) + ' psk "12345678901234567890123456789012…
195 dev[0].set_network_quoted(id, "psk", "123456768")
196 …dev[0].set_network_quoted(id, "psk", "123456789012345678901234567890123456789012345678901234567890…
197 if dev[0].get_network(id, "psk") != '*':
200 if "FAIL" not in dev[0].request('SET_NETWORK ' + str(id) + ' eap UNKNOWN'):
203 if "FAIL" not in dev[0].request('SET_NETWORK ' + str(id) + ' password "foo'):
206 if "FAIL" not in dev[0].request('SET_NETWORK ' + str(id) + ' wep_key0 "foo'):
208 if "FAIL" not in dev[0].request('SET_NETWORK ' + str(id) + ' wep_key0 "12345678901234567"'):
212 dev[0].set_network_quoted(id, "wep_key0", "1234")
213 dev[0].set_network_quoted(id, "wep_key1", "12345")
214 dev[0].set_network_quoted(id, "wep_key2", "1234567890123")
215 dev[0].set_network_quoted(id, "wep_key3", "1234567890123456")
217 dev[0].set_network(id, "go_p2p_dev_addr", "any")
218 if dev[0].get_network(id, "go_p2p_dev_addr") is not None:
220 if "FAIL" not in dev[0].request('SET_NETWORK ' + str(id) + ' go_p2p_dev_addr 00:11:22:33:44'):
222 if "FAIL" not in dev[0].request('SET_NETWORK ' + str(id) + ' p2p_client_list 00:11:22:33:44'):
224 … if "FAIL" in dev[0].request('SET_NETWORK ' + str(id) + ' p2p_client_list 00:11:22:33:44:55 00:1'):
226 if dev[0].get_network(id, "p2p_client_list") != "00:11:22:33:44:55":
229 if "FAIL" not in dev[0].request('SET_NETWORK ' + str(id) + ' auth_alg '):
231 if "FAIL" not in dev[0].request('SET_NETWORK ' + str(id) + ' auth_alg FOO'):
234 if "FAIL" not in dev[0].request('SET_NETWORK ' + str(id) + ' proto '):
236 if "FAIL" not in dev[0].request('SET_NETWORK ' + str(id) + ' proto FOO'):
239 if "FAIL" not in dev[0].request('SET_NETWORK ' + str(id) + ' pairwise '):
241 if "FAIL" not in dev[0].request('SET_NETWORK ' + str(id) + ' pairwise FOO'):
243 if "FAIL" not in dev[0].request('SET_NETWORK ' + str(id) + ' pairwise WEP40'):
246 if "OK" not in dev[0].request('BSSID ' + str(id) + ' 00:11:22:33:44:55'):
250 if "OK" not in dev[0].request('BSSID ' + str(id) + ' 00:00:00:00:00:00'):
256 if "FAIL" not in dev[0].request('BSSID ' + str(id) + ' 00:11:22:33:44'):
258 if "FAIL" not in dev[0].request('BSSID ' + str(id)):
269 dev[0].set_network(id, "bssid_ignore", val)
270 res = dev[0].get_network(id, "bssid_ignore")
273 dev[0].set_network(id, "bssid_accept", val)
274 res = dev[0].get_network(id, "bssid_accept")
284 if "FAIL" not in dev[0].request("SET_NETWORK %d bssid_ignore %s" % (id, val)):
290 id = dev[0].add_network()
298 if "FAIL" not in dev[0].request("SET_NETWORK " + str(id) + ' ssid ' + val):
307 id = dev[0].add_network()
308 ev = dev[0].wait_event(["CTRL-EVENT-NETWORK-ADDED %d" % id])
311 ev = dev[0].wait_global_event(["CTRL-EVENT-NETWORK-ADDED %d" % id], timeout=10)
316 if str(id) in res:
318 res = dev[0].request("LIST_NETWORKS LAST_ID=%d" % (id - 2))
319 if str(id) not in res:
331 if str(id) in ev:
337 if str(id) in ev:
355 id = dev[0].add_network()
356 dev[0].set_network_quoted(id, "ssid", ssid)
358 res = dev[0].request("DUP_NETWORK {} {} {}".format(src, id, f))
361 dev[0].connect_network(id)
365 if "FAIL" not in dev[0].request("DUP_NETWORK %d " % id):
367 if "FAIL" not in dev[0].request("DUP_NETWORK %d %d" % (id, id)):
371 if "FAIL" not in dev[0].request("DUP_NETWORK %d 123456 " % id):
373 if "FAIL" not in dev[0].request("DUP_NETWORK %d %d foo" % (id, id)):
376 if "OK" not in dev[0].request("DUP_NETWORK %d %d ssid" % (id, id)):
389 id = dev[0].add_network()
390 dev[0].set_network_quoted(id, "ssid", ssid)
392 …ev[0].global_request("DUP_NETWORK {} {} {} {} {}".format(dev[0].ifname, dev[0].ifname, src, id, f))
395 dev[0].connect_network(id)
403 …f "FAIL" not in dev[0].global_request("DUP_NETWORK %s %s %d" % (dev[0].ifname, dev[0].ifname, id)):
405 …" not in dev[0].global_request("DUP_NETWORK %s %s %d %d" % (dev[0].ifname, dev[0].ifname, id, id)):
408 … in dev[0].global_request("DUP_NETWORK %s %s %d %d ssid" % (dev[0].ifname, dev[0].ifname, id, id)):
412 id = dev.add_cred()
416 if " " + str(id) not in ev:
418 return id
420 def set_cred(dev, id, field, value): argument
421 dev.set_cred(id, field, value)
425 if " " + str(id) + " " not in ev:
430 def set_cred_quoted(dev, id, field, value): argument
431 dev.set_cred_quoted(id, field, value)
435 if " " + str(id) + " " not in ev:
440 def remove_cred(dev, id): argument
441 dev.remove_cred(id)
445 if " " + str(id) not in ev:
464 id = add_cred(dev[0])
466 set_cred(dev[0], id, "temporary", "1")
467 set_cred(dev[0], id, "priority", "1")
468 set_cred(dev[0], id, "pcsc", "1")
469 set_cred(dev[0], id, "sim_num", "0")
470 set_cred_quoted(dev[0], id, "private_key_passwd", "test")
471 set_cred_quoted(dev[0], id, "domain_suffix_match", "test")
472 set_cred_quoted(dev[0], id, "phase1", "test")
473 set_cred_quoted(dev[0], id, "phase2", "test")
475 if "FAIL" not in dev[0].request("SET_CRED " + str(id) + " eap FOO"):
478 if "FAIL" not in dev[0].request("SET_CRED " + str(id) + " username 12xa"):
482 if "FAIL" not in dev[0].request("SET_CRED " + str(id) + " roaming_consortium " + i):
484 if "FAIL" not in dev[0].request("SET_CRED " + str(id) + " home_ois " + '"' + i + '"'):
486 … if "FAIL" not in dev[0].request("SET_CRED " + str(id) + " required_home_ois " + '"' + i + '"'):
488 …if "FAIL" not in dev[0].request("SET_CRED " + str(id) + " home_ois " + '"112233' + 36*",112233" + …
490 …if "FAIL" in dev[0].request("SET_CRED " + str(id) + " home_ois " + '"112233' + 35*",112233" + '"'):
493 …dev[0].set_cred(id, "excluded_ssid", "00112233445566778899aabbccddeeff00112233445566778899aabbccdd…
494 …if "FAIL" not in dev[0].request("SET_CRED " + str(id) + " excluded_ssid 00112233445566778899aabbcc…
497 if "FAIL" not in dev[0].request("SET_CRED " + str(id) + " foo 4142"):
507 if "FAIL" not in dev[0].request("SET_CRED " + str(id) + " " + t):
519 remove_cred(dev[0], id)
525 id = add_cred(dev[0])
565 set_cred_quoted(dev[0], id, v[0], v[1])
567 set_cred(dev[0], id, v[0], v[1])
568 val = dev[0].get_cred(id, v[0])
580 remove_cred(dev[0], id)
584 id = add_cred(dev[0])
585 set_cred_quoted(dev[0], id, "domain", "foo.example.com")
586 id = add_cred(dev[0])
587 set_cred_quoted(dev[0], id, "domain", "bar.example.com")
588 id = add_cred(dev[0])
589 set_cred_quoted(dev[0], id, "domain", "foo.example.com")
599 id = add_cred(dev[0])
600 set_cred_quoted(dev[0], id, "domain", "foo.example.com")
601 set_cred_quoted(dev[0], id, "provisioning_sp", "sp.foo.example.com")
602 id = add_cred(dev[0])
603 set_cred_quoted(dev[0], id, "domain", "bar.example.com")
604 set_cred_quoted(dev[0], id, "provisioning_sp", "sp.bar.example.com")
605 id = add_cred(dev[0])
606 set_cred_quoted(dev[0], id, "domain", "foo.example.com")
607 set_cred_quoted(dev[0], id, "provisioning_sp", "sp.foo.example.com")
620 id = add_cred(dev[0])
621 set_cred_quoted(dev[0], id, "realm", "relatively.long.realm.test%d.example.com" % i)
638 id = dev[0].add_network()
639 dev[0].set_network_quoted(id, "ssid", "test")
640 dev[0].set_network(id, "key_mgmt", "NONE")
641 dev[0].request("ENABLE_NETWORK " + str(id) + " no-connect")
1204 id = dev[0].connect("test", key_mgmt="NONE", scan_freq="2412",
1206 if "OK" not in dev[0].request("DISABLE_NETWORK " + str(id)):
1208 if "OK" not in dev[0].request("ENABLE_NETWORK " + str(id) + " no-connect"):
1212 if "OK" not in dev[0].request("ENABLE_NETWORK " + str(id)):
1215 if "OK" not in dev[0].request("DISABLE_NETWORK " + str(id)):
1345 id = dev[0].connect("test", key_mgmt="NONE", scan_freq="2412")
1373 id = dev[0].add_network()
1374 if "FAIL" not in dev[0].request("CTRL-RSP-foo-%d:" % id):
1378 if "OK" not in dev[0].request("CTRL-RSP-%s-%d:" % (req, id)):
1380 if "OK" not in dev[0].request("CTRL-RSP-%s-%d:" % (req, id)):
1609 id = wpas.add_network()
1610 wpas.set_network(id, "mode", "2")
1611 wpas.set_network_quoted(id, "ssid", "wpas-ap-open")
1612 wpas.set_network(id, "key_mgmt", "NONE")
1613 wpas.set_network(id, "frequency", "2412")
1614 wpas.set_network(id, "scan_freq", "2412")
1615 wpas.select_network(id)