mirror of
https://github.com/Telecominfraproject/wlan-lanforge-scripts.git
synced 2025-11-01 03:07:56 +00:00
ADD addtional parameters to support EAP security modes for roam test
Signed-off-by: anil-tegala <anil.tegala@candelatech.com>
This commit is contained in:
@@ -2963,8 +2963,11 @@ class lf_tests(lf_libs):
|
|||||||
twog_radio="1.1.wiphy4", sixg_radio="1.1.wiphy4",
|
twog_radio="1.1.wiphy4", sixg_radio="1.1.wiphy4",
|
||||||
band="twog", sniff_radio_="1.1.wiphy5", num_sta=1, security="wpa2", security_key="Openwifi",
|
band="twog", sniff_radio_="1.1.wiphy5", num_sta=1, security="wpa2", security_key="Openwifi",
|
||||||
ssid="OpenWifi", upstream="1.1.eth1", duration=None, iteration=1, channel="11", option="ota",
|
ssid="OpenWifi", upstream="1.1.eth1", duration=None, iteration=1, channel="11", option="ota",
|
||||||
dut_name=["edgecore_eap101", "edgecore_eap102"], traffic_type="lf_udp", identity="identity",
|
dut_name=["edgecore_eap101", "edgecore_eap102"], traffic_type="lf_udp", eap_method=None,
|
||||||
ttls_pass="ttls_pass", sta_type="11r"):
|
eap_identity=None, eap_password=None, pairwise_cipher=None, groupwise_cipher=None,
|
||||||
|
private_key=None, pk_passwd=None, ca_cert=None, eap_phase1=None, eap_phase2=None,
|
||||||
|
soft_roam=False, sta_type="11r"):
|
||||||
|
|
||||||
roam_obj = RoamTest(lanforge_ip=self.manager_ip,
|
roam_obj = RoamTest(lanforge_ip=self.manager_ip,
|
||||||
lanforge_port=self.manager_http_port,
|
lanforge_port=self.manager_http_port,
|
||||||
lanforge_ssh_port=self.manager_ssh_port,
|
lanforge_ssh_port=self.manager_ssh_port,
|
||||||
@@ -2998,20 +3001,29 @@ class lf_tests(lf_libs):
|
|||||||
port="8888",
|
port="8888",
|
||||||
band_cc="5g",
|
band_cc="5g",
|
||||||
timeout="10",
|
timeout="10",
|
||||||
identity=identity,
|
eap_method=eap_method,
|
||||||
ttls_pass=ttls_pass,
|
eap_identity=eap_identity,
|
||||||
soft_roam=False,
|
eap_password=eap_password,
|
||||||
|
pairwise_cipher=pairwise_cipher,
|
||||||
|
groupwise_cipher=groupwise_cipher,
|
||||||
|
private_key=private_key,
|
||||||
|
pk_passwd=pk_passwd,
|
||||||
|
ca_cert=ca_cert,
|
||||||
|
eap_phase1=eap_phase1,
|
||||||
|
eap_phase2=eap_phase2,
|
||||||
|
soft_roam=soft_roam,
|
||||||
sta_type=sta_type,
|
sta_type=sta_type,
|
||||||
|
ieee80211w="1",
|
||||||
multicast=False
|
multicast=False
|
||||||
)
|
)
|
||||||
x = os.getcwd()
|
x = os.getcwd()
|
||||||
logging.info("Current Working Directory :", x)
|
logging.info(f"Current Working Directory : {x}")
|
||||||
file = roam_obj.generate_csv()
|
file = roam_obj.generate_csv()
|
||||||
logging.info("CSV File :", file)
|
logging.info(f"CSV File : {file}")
|
||||||
roam_obj.precleanup()
|
roam_obj.precleanup()
|
||||||
kernel, message = roam_obj.run(file_n=file)
|
kernel, message = roam_obj.run(file_n=file)
|
||||||
report_dir_name = roam_obj.generate_report(csv_list=file, kernel_lst=kernel, current_path=str(x) + "/11r")
|
report_dir_name = roam_obj.generate_report(csv_list=file, kernel_lst=kernel, current_path=str(x) + "/11r")
|
||||||
logging.info(report_dir_name)
|
logging.info(f"Test Report Directory : {report_dir_name}")
|
||||||
|
|
||||||
|
|
||||||
if __name__ == '__main__':
|
if __name__ == '__main__':
|
||||||
|
|||||||
@@ -194,12 +194,11 @@ class HardRoam(Realm):
|
|||||||
ca_cert=None,
|
ca_cert=None,
|
||||||
eap_phase1=None,
|
eap_phase1=None,
|
||||||
eap_phase2=None,
|
eap_phase2=None,
|
||||||
# identity=None,
|
|
||||||
# ttls_pass=None,
|
|
||||||
log_file=False,
|
log_file=False,
|
||||||
debug=False,
|
debug=False,
|
||||||
soft_roam=False,
|
soft_roam=False,
|
||||||
sta_type=None,
|
sta_type=None,
|
||||||
|
ieee80211w=None,
|
||||||
multicast=None
|
multicast=None
|
||||||
):
|
):
|
||||||
super().__init__(lanforge_ip,
|
super().__init__(lanforge_ip,
|
||||||
@@ -235,7 +234,7 @@ class HardRoam(Realm):
|
|||||||
self.client_list = []
|
self.client_list = []
|
||||||
self.dut_name = dut_name
|
self.dut_name = dut_name
|
||||||
self.pcap_obj = lf_pcap.LfPcap(host=self.lanforge_ip, port=self.lanforge_port)
|
self.pcap_obj = lf_pcap.LfPcap(host=self.lanforge_ip, port=self.lanforge_port)
|
||||||
self.lf_csv_obj = lf_csv.lf_csv()
|
self.lf_csv_obj = lf_csv()
|
||||||
self.traffic_type = traffic_type
|
self.traffic_type = traffic_type
|
||||||
self.roam_delay = roaming_delay
|
self.roam_delay = roaming_delay
|
||||||
self.sta_type = sta_type
|
self.sta_type = sta_type
|
||||||
@@ -269,6 +268,7 @@ class HardRoam(Realm):
|
|||||||
self.debug = debug
|
self.debug = debug
|
||||||
self.mac_data = None
|
self.mac_data = None
|
||||||
self.soft_roam = soft_roam
|
self.soft_roam = soft_roam
|
||||||
|
self.ieee80211w = ieee80211w
|
||||||
self.multicast = multicast
|
self.multicast = multicast
|
||||||
print("Number of iteration : ", self.iteration)
|
print("Number of iteration : ", self.iteration)
|
||||||
# logging.basicConfig(filename='roam.log', filemode='w', level=logging.INFO, force=True)
|
# logging.basicConfig(filename='roam.log', filemode='w', level=logging.INFO, force=True)
|
||||||
@@ -697,10 +697,10 @@ class HardRoam(Realm):
|
|||||||
for i in range(self.num_sta):
|
for i in range(self.num_sta):
|
||||||
file = 'test_client_' + str(i) + '.csv'
|
file = 'test_client_' + str(i) + '.csv'
|
||||||
if self.multicast == "True":
|
if self.multicast == "True":
|
||||||
lf_csv_obj = lf_csv.lf_csv(_columns=['Iterations', 'bssid1', 'bssid2', "PASS/FAIL", "Remark"], _rows=[],
|
lf_csv_obj = lf_csv(_columns=['Iterations', 'bssid1', 'bssid2', "PASS/FAIL", "Remark"], _rows=[],
|
||||||
_filename=file)
|
_filename=file)
|
||||||
else:
|
else:
|
||||||
lf_csv_obj = lf_csv.lf_csv(_columns=['Iterations', 'bssid1', 'bssid2', "Roam Time(ms)", "PASS/FAIL",
|
lf_csv_obj = lf_csv(_columns=['Iterations', 'bssid1', 'bssid2', "Roam Time(ms)", "PASS/FAIL",
|
||||||
"Pcap file Name", "Log File", "Remark"], _rows=[], _filename=file)
|
"Pcap file Name", "Log File", "Remark"], _rows=[], _filename=file)
|
||||||
# "Packet loss",
|
# "Packet loss",
|
||||||
file_name.append(file)
|
file_name.append(file)
|
||||||
@@ -1845,7 +1845,7 @@ class HardRoam(Realm):
|
|||||||
for i in csv_list:
|
for i in csv_list:
|
||||||
print("i", i)
|
print("i", i)
|
||||||
logging.info("i, " + i)
|
logging.info("i, " + i)
|
||||||
lf_csv_obj = lf_csv.lf_csv()
|
lf_csv_obj = lf_csv()
|
||||||
h = lf_csv_obj.read_csv(file_name=i, column="PASS/FAIL")
|
h = lf_csv_obj.read_csv(file_name=i, column="PASS/FAIL")
|
||||||
count = h.count("PASS")
|
count = h.count("PASS")
|
||||||
print(count)
|
print(count)
|
||||||
@@ -2008,7 +2008,7 @@ class HardRoam(Realm):
|
|||||||
", including its BSSID before and after roaming, the time of roaming, the name of "
|
", including its BSSID before and after roaming, the time of roaming, the name of "
|
||||||
"the capture file, and any relevant remarks.")
|
"the capture file, and any relevant remarks.")
|
||||||
report.build_objective()
|
report.build_objective()
|
||||||
lf_csv_obj = lf_csv.lf_csv()
|
lf_csv_obj = lf_csv()
|
||||||
if self.multicast == "True":
|
if self.multicast == "True":
|
||||||
y = lf_csv_obj.read_csv(file_name=str(report_path) + "/csv_data/" + str(x), column="Iterations")
|
y = lf_csv_obj.read_csv(file_name=str(report_path) + "/csv_data/" + str(x), column="Iterations")
|
||||||
z = lf_csv_obj.read_csv(file_name=str(report_path) + "/csv_data/" + str(x), column="bssid1")
|
z = lf_csv_obj.read_csv(file_name=str(report_path) + "/csv_data/" + str(x), column="bssid1")
|
||||||
|
|||||||
Reference in New Issue
Block a user