summaryrefslogtreecommitdiff
path: root/tmap
diff options
context:
space:
mode:
Diffstat (limited to 'tmap')
-rwxr-xr-xtmap6
1 files changed, 3 insertions, 3 deletions
diff --git a/tmap b/tmap
index 90d4971..2871e92 100755
--- a/tmap
+++ b/tmap
@@ -66,7 +66,7 @@ def getBanner(host, port, wait, notor):
try:
banner = sckt.recv(80)
sckt.close()
- return banner.decode().replace('\n','')
+ return banner.decode().replace('\n','\\n').replace('\r','\\r')
except KeyboardInterrupt:
exit()
except Exception as e:
@@ -77,9 +77,9 @@ def getBanner(host, port, wait, notor):
payload = "GET / HTTP/1.1\r\nHost: " + str(host) + "\r\nUser-Agent: Mozilla/5.0\r\n\r\n"
## Encode the payload and send it all
sckt.sendall(payload.encode())
- banner = sckt.recv(20)
+ banner = sckt.recv(80)
sckt.close()
- return banner.decode().replace('\n','')
+ return banner.decode().replace('\n','\\n').replace('\r','\\r')
except:
return "banner_error"
else: