From 511e8bd1a0ccbfde03f58edfcf6eac5d3bb0cf46 Mon Sep 17 00:00:00 2001 From: Kirill Tkachuk Date: Thu, 30 Jun 2022 11:40:34 +0300 Subject: [PATCH] Add aliases for psql and mongodb for nmap input compatibility --- ncrack-services | 2 ++ ncrack.cc | 4 ++-- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/ncrack-services b/ncrack-services index 103ba9e..a4056d0 100644 --- a/ncrack-services +++ b/ncrack-services @@ -34,6 +34,7 @@ mysql 3306/tcp ms-wbt-server 3389/tcp rdp 3389/tcp psql 5432/tcp +postgresql 5432/tcp vnc 5801/tcp vnc 5900/tcp vnc 5901/tcp @@ -45,4 +46,5 @@ couchbase 8091/tcp cassandra 9160/tcp cassandra 9042/tcp mongodb 27017/tcp +mongod 27017/tcp cvs 2401/tcp diff --git a/ncrack.cc b/ncrack.cc index 0e7eeec..a228cc7 100644 --- a/ncrack.cc +++ b/ncrack.cc @@ -804,13 +804,13 @@ call_module(nsock_pool nsp, Connection *con) ncrack_webform(nsp, con); else if (!strcmp(name, "winrm")) ncrack_winrm(nsp, con); - else if (!strcmp(name, "mongodb")) + else if (!strcmp(name, "mongodb") || !strcmp(name, "mongod")) ncrack_mongodb(nsp, con); else if (!strcmp(name, "pop3s")) ncrack_pop3(nsp, con); else if (!strcmp(name, "mysql")) ncrack_mysql(nsp, con); - else if (!strcmp(name, "psql")) + else if (!strcmp(name, "psql") || !strcmp(name, "postgresql")) ncrack_psql(nsp, con); else if (!strcmp(name, "mssql")) ncrack_mssql(nsp, con);