fix: update API routes for sniffer and bridge operations for consistency
All checks were successful
Build and Deploy MITM Webserver / build (push) Successful in 7s

This commit is contained in:
2025-11-27 15:26:55 +01:00
parent e951fed50d
commit ff411da6e5
4 changed files with 6 additions and 6 deletions

View File

@@ -350,7 +350,7 @@ def full_state(
"bridges": get_bridges(), # uses NDB internally
}
@router.post("/create")
@router.post("/bridge/create")
def create_bridge(req: BridgeCreateRequest, ip: IPRoute = Depends(get_iproute)):
if bridge_exists(req.name, ip):
raise HTTPException(400, f"Bridge {req.name} already exists")
@@ -382,7 +382,7 @@ def create_bridge(req: BridgeCreateRequest, ip: IPRoute = Depends(get_iproute)):
}
@router.post("/remove")
@router.post("/bridge/remove")
def remove_bridge(req: BridgeRemoveRequest, ip: IPRoute = Depends(get_iproute)):
if not bridge_exists(req.name, ip):
raise HTTPException(404, f"Bridge {req.name} not found")