{"record":{"id":"ff84650272ba8e27","repo":"XX-net/XX-Net","slug":"control-req-s-s-s","errorCode":null,"errorMessage":"Control Req %s %s %s ","messagePattern":"Control Req (.+?) (.+?) (.+?) ","errorType":"console","errorClass":null,"httpStatus":null,"severity":"info","filePath":"code/default/smart_router/local/web_control.py","lineNumber":39,"sourceCode":"\n\nclass ControlHandler(simple_http_server.HttpServerHandler):\n    def __init__(self, client_address, headers, command, path, rfile, wfile):\n        self.client_address = client_address\n        self.headers = headers\n        self.command = command\n        self.path = path\n        self.rfile = rfile\n        self.wfile = wfile\n\n    def do_GET(self):\n        path = urlparse(self.path).path\n        if path == \"/log\":\n            return self.req_log_handler()\n        elif path == \"/status\":\n            return self.req_status()\n        else:\n            xlog.warn('Control Req %s %s %s ', self.address_string(), self.command, self.path)\n\n    def do_POST(self):\n        xlog.debug('Web_control %s %s %s ', self.address_string(), self.command, self.path)\n\n        path = urlparse(self.path).path\n        if path == '/rules':\n            return self.req_rules_handler()\n        elif path == \"/cache\":\n            return self.req_cache_handler()\n        elif path == \"/config\":\n            return self.req_config_handler()\n        else:\n            xlog.info('%s \"%s %s HTTP/1.1\" 404 -', self.address_string(), self.command, self.path)\n            return self.send_not_found()\n\n    def req_log_handler(self):\n        req = urlparse(self.path).query\n        reqs = self.unpack_reqs(parse_qs(req, keep_blank_values=True))","sourceCodeStart":21,"sourceCodeEnd":57,"githubUrl":"https://github.com/XX-net/XX-Net/blob/cfa5bc17b67676e467f37ec50766127e0ab5f0aa/code/default/smart_router/local/web_control.py#L21-L57","documentation":"The web control interface received a GET for a path other than /log or /status; it just warns with client address, command, and path.","triggerScenarios":"GET request to the control port for an unknown path, e.g. /favicon.ico, /, or scanner URLs.","commonSituations":"Browsers auto-requesting favicon.ico, monitoring tools probing /, port scanners hitting the control port, typos in the URL.","solutions":["Ignore — harmless unless frequent; it is only a warning","Restrict access to the control port (bind to 127.0.0.1, firewall)","Add routes for / or /favicon.ico to silence noise","Ensure scanners cannot reach the port"],"exampleFix":null,"handlingStrategy":"validation","validationCode":"if path not in ('/log','/status'): return 404 quietly","typeGuard":null,"tryCatchPattern":null,"preventionTips":["Bind the control interface to localhost","Expect browser favicon probes; ignore"],"tags":["http","web-control","unknown-path"],"backgroundTag":"http-404-not-found","analyzedSha":"cfa5bc17b67676e467f37ec50766127e0ab5f0aa","analyzedAt":"2026-08-27T19:28:28.225Z","schemaVersion":2},"datasetVersion":"2026-08-28T00:17:15.603Z"}