present better error message for clueless users :)

This commit is contained in:
van Hauser 2016-09-03 10:56:32 +02:00
commit d89983364b
2 changed files with 6 additions and 0 deletions

View file

@ -4,6 +4,7 @@ Changelog for hydra
Release 8.4-dev
* New command line option -y which disables -x 1aA interpretation, thanks to crondaemon for the patch
* The protocols vnc, xmpp, telnet, imap, nntp and pcanywhere got accidentially long sleep commands due a patch in 8.2, fixed
* Added special error message for clueless users :)
Release 8.3

View file

@ -2584,6 +2584,11 @@ int main(int argc, char *argv[]) {
help(0);
}
} else {
if (strstr(argv[optind], "://") != NULL) {
printf("[ERROR] Invalid target definition!\n");
printf("[ERROR] Either you use \"www.example.com module [optional-module-parameters]\" *or* you use the \"module://www.example.com/optional-module-parameters\" syntax!\n");
exit(-1);
}
hydra_options.server = argv[optind];
cmdlinetarget = argv[optind];
hydra_options.service = argv[optind + 1];