#!/usr/bin/env python3 """Dump login.html head + filter/nat relevant to CNA delay.""" from __future__ import annotations import sys SCRIPT = r""" :put "===FILTER===" /ip firewall filter print :put "===RAW===" /ip firewall raw print :put "===LOGIN-HEAD===" /file print detail where name="hotspot/login.html" or name="portal/login.html" :put "===IPV6-ND-IFACES===" /ipv6 nd print :put "===HS-HOSTS===" /ip hotspot host print count-only :put "===HS-ACTIVE===" /ip hotspot active print count-only """ if __name__ == "__main__": target = sys.argv[1] if len(sys.argv) > 1 else "hub" if target == "nko": from mk_rb4011_exec import run else: from mk_hub_exec import run print(run(SCRIPT, timeout=60))