From 3690c8ec95dd07ce6c523883354188e9fff968c3 Mon Sep 17 00:00:00 2001 From: Klaus-Uwe Mitterer Date: Mon, 18 Jul 2016 22:21:32 +0200 Subject: [PATCH] Add meaningful message for services that are not yet implemented. --- servertools/__init__.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/servertools/__init__.py b/servertools/__init__.py index 882b4b4..657b414 100644 --- a/servertools/__init__.py +++ b/servertools/__init__.py @@ -53,7 +53,7 @@ class TCPHandler(socketserver.StreamRequestHandler): elif command in ("heartbeat", "hb", "ping"): return "OK: Still here? Wow." elif command in ("stat", "status"): - return False + return "UA: Not currently implemented." elif command in ("ssl", "tls"): try: if listIncluded(str(content[1]), SSL): @@ -69,11 +69,11 @@ class TCPHandler(socketserver.StreamRequestHandler): except: return "ER: Could not verify SSL certificate on %s:%i. Is the server down?" % (content[1], content[2]) elif command == "port": - return False + return "UA: Not currently implemented." elif command in ("req", "request"): return "NI: Requesting monitoring is not yet implemented." elif command == "help": - return False + return "UA: Not currently implemented." else: return "IM: Unknown command %s." % command # except TypeError: