tc test 4
All checks were successful
Build and Deploy MITM Webserver / build (push) Successful in 9s
All checks were successful
Build and Deploy MITM Webserver / build (push) Successful in 9s
This commit is contained in:
@@ -564,6 +564,12 @@ def _sigterm(_signum: int, _frame: object) -> None:
|
|||||||
raise KeyboardInterrupt
|
raise KeyboardInterrupt
|
||||||
|
|
||||||
|
|
||||||
|
def _json_safe(value: object) -> object:
|
||||||
|
if isinstance(value, bytes):
|
||||||
|
return value.decode("utf-8", "replace")
|
||||||
|
return value
|
||||||
|
|
||||||
|
|
||||||
def _ensure_clean_clsact(iface: str) -> None:
|
def _ensure_clean_clsact(iface: str) -> None:
|
||||||
subprocess.run(["tc", "qdisc", "del", "dev", iface, "clsact"], check=False, capture_output=True, text=True)
|
subprocess.run(["tc", "qdisc", "del", "dev", iface, "clsact"], check=False, capture_output=True, text=True)
|
||||||
_run_checked(["tc", "qdisc", "add", "dev", iface, "clsact"])
|
_run_checked(["tc", "qdisc", "add", "dev", iface, "clsact"])
|
||||||
@@ -672,8 +678,8 @@ def main() -> int:
|
|||||||
{
|
{
|
||||||
"status": "collector_started",
|
"status": "collector_started",
|
||||||
"ifaces": sorted(TARGET_INTERFACES),
|
"ifaces": sorted(TARGET_INTERFACES),
|
||||||
"ingress_program": ingress_prog_name,
|
"ingress_program": _json_safe(ingress_prog_name),
|
||||||
"egress_program": egress_prog_name,
|
"egress_program": _json_safe(egress_prog_name),
|
||||||
"build_dir": str(args.build_dir),
|
"build_dir": str(args.build_dir),
|
||||||
},
|
},
|
||||||
separators=(",", ":"),
|
separators=(",", ":"),
|
||||||
|
|||||||
Reference in New Issue
Block a user