From eb064c4222964ecac9dc757ad8c847b130c43deb Mon Sep 17 00:00:00 2001 From: van Hauser Date: Thu, 14 Jun 2018 02:44:31 +0200 Subject: [PATCH] support uncommon mysql ports --- CHANGES | 1 + Makefile.am | 0 hydra-mysql.c | 2 +- hydra.h | 0 4 files changed, 2 insertions(+), 1 deletion(-) mode change 100755 => 100644 Makefile.am mode change 100755 => 100644 hydra.h diff --git a/CHANGES b/CHANGES index e49e9bf..02f7e81 100644 --- a/CHANGES +++ b/CHANGES @@ -3,6 +3,7 @@ Changelog for hydra Release 8.7-dev +* mysql module: a non-default port was not working, fixed * added -w timeout support to ssh module * fixed various memory leaks in http-form module * corrected hydra return code to be 0 on success diff --git a/Makefile.am b/Makefile.am old mode 100755 new mode 100644 diff --git a/hydra-mysql.c b/hydra-mysql.c index fdf1e81..0fda989 100644 --- a/hydra-mysql.c +++ b/hydra-mysql.c @@ -212,7 +212,7 @@ int32_t start_mysql(int32_t sock, char *ip, int32_t port, unsigned char options, } } /*mysql_options(&mysql,MYSQL_OPT_COMPRESS,0); */ - if (!mysql_real_connect(mysql, hydra_address2string(ip), login, pass, database, 0, NULL, 0)) { + if (!mysql_real_connect(mysql, hydra_address2string(ip), login, pass, database, port, NULL, 0)) { int32_t my_errno = mysql_errno(mysql); if (debug) diff --git a/hydra.h b/hydra.h old mode 100755 new mode 100644