From ff4deb768e48e977c582dccebfe3a0b248c5f871 Mon Sep 17 00:00:00 2001 From: van Hauser Date: Thu, 11 Oct 2018 19:30:55 +0200 Subject: [PATCH] fix no target crash --- hydra.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/hydra.c b/hydra.c index 53e1ff7..6a0413d 100644 --- a/hydra.c +++ b/hydra.c @@ -3290,6 +3290,9 @@ int main(int argc, char *argv[]) { tmpptr++; tmpptr++; } + } else if (hydra_options.server == NULL) { + fprintf(stderr, "Error: no target server given, nor -M option used\n"); + exit(-1); } else if (index(hydra_options.server, '/') != NULL) { if (cmdtarget == NULL) bail("You seem to mix up \"service://target:port/options\" syntax with \"target service options\" syntax. Read the README on how to use hydra correctly!");