Lines Matching refs:server

39 from http.server import HTTPServer, BaseHTTPRequestHandler
166 def add_standard_headers(server): argument
167 server.send_header('Cache-Control', 'no-cache, no-store, must-revalidate')
168 server.send_header('Access-Control-Allow-Origin', '*')
169 server.send_header('Access-Control-Allow-Methods', 'POST, GET, OPTIONS')
170server.send_header('Access-Control-Allow-Headers', WINSCOPE_TOKEN_HEADER + ', Content-Type, Conten…
171 server.send_header('Access-Control-Expose-Headers', 'Winscope-Proxy-Version')
172 server.send_header(WINSCOPE_VERSION_HEADER, VERSION)
173 server.end_headers()
180 def process(self, server, path): argument
270 def process(self, server, path): argument
278 server.respond(HTTPStatus.OK, j.encode("utf-8"), "text/json")
282 def process(self, server, path): argument
284 self.process_with_device(server, path[1:], path[0])
289 def process_with_device(self, server, path, device_id): argument
294 def process_with_device(self, server, path, device_id): argument
309 server.send_response(HTTPStatus.OK)
310 server.send_header('X-Content-Type-Options', 'nosniff')
311 server.send_header('Content-type', 'application/octet-stream')
312 add_standard_headers(server)
317 server.wfile.write(buf)
420 def process_with_device(self, server, path, device_id): argument
422 length = int(server.headers["Content-Length"])
428 requested_types = json.loads(server.rfile.read(length).decode("utf-8"))
434 server.respond(HTTPStatus.OK, b'', "text/plain")
445 server.respond(HTTPStatus.OK, b'', "text/plain")
449 def process_with_device(self, server, path, device_id): argument
460 server.respond(HTTPStatus.OK, out, "text/plain")
469 def process_with_device(self, server, path, device_id): argument
473server.respond(HTTPStatus.OK, str(TRACE_THREADS[device_id].is_alive()).encode("utf-8"), "text/plai…
477 def process_with_device(self, server, path, device_id): argument
479 length = int(server.headers["Content-Length"])
485 requested_types = json.loads(server.rfile.read(length).decode("utf-8"))
506 server.respond(HTTPStatus.OK, b'', "text/plain")
510 def __init__(self, request, client_address, server): argument
518 super().__init__(request, client_address, server)