summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rwxr-xr-xtmap9
1 files changed, 9 insertions, 0 deletions
diff --git a/tmap b/tmap
index e54c447..bc7f360 100755
--- a/tmap
+++ b/tmap
@@ -38,6 +38,7 @@ def main():
## Define and parse the arguments
parser = argparse.ArgumentParser(description="Simple port scanner that works over Tor")
+ parser.add_argument("--version", dest="version", help="print version info and exit", action="store_true")
parser.add_argument("HOSTS", help="IP or domain to scan", default="empty_host", nargs="?")
parser.add_argument("-H", "--hosts", metavar="HOSTS", dest="tgtHost", help="IP or domain to scan", default="empty_host_option")
parser.add_argument("-p", "--ports", metavar="PORTS", dest="tgtPort", help="ports to scan", default="21,22,23,25,53,80,443,8080,8333,9050,9150")
@@ -47,6 +48,14 @@ def main():
args = parser.parse_args()
+ ## Version argument
+ if args.version:
+ print("Tmap 1.0.0")
+ print("License GPLv3+: GNU GPL version 3 or later <https://gnu.org/licenses/gpl.html>")
+ print("This is free software: you are free to change and redistribute it.")
+ print("There is NO WARRANTY, to the extent permitted by law.")
+ exit()
+
## Combine HOST and --hosts values
if args.HOSTS == "empty_host":
if args.tgtHost == "empty_host_option":