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

@ -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];