1

I am trying to run a ncrack command of the following format:

ncrack -P filePath1 filePath2 --user user1, user2, user3 ipAddress:port

and I get the following error;

enter image description here

Does anybody know why I'm getting this error and how to fix it?

1 Answer 1

1

The -P option doesn't take multiple arguments according to the man page, maybe concatenate the files at filePath1 and filePath2?

ncrack -P filePath1 --user user1,user2,user3 ipAddress:port

At least, that format just worked on my terminal.

From the man page of ncrack:

-P <filename> (Specify password list)

Specify your own password list by giving the path to the filename as argument to this option.

So this parameter takes only one argument.

On the other side

Everything on the Ncrack command-line that isn't an option (or an option argument) is treated as a target host specification.

So this explains the errors displayed.

This can be verified: If you look closer into the code

ncrack code

you can see that if there is no IP delivered it tries to resolve the given hostname and if that fails ncrack shows this message.

Version 0.7 in comparison only displays one error message:

ncrack 0.7 output

and you have to delete the spaces between the users (which yields to You must specify either a service name or a port (or both): user2,).

So you can merge the two password files eg. using:

cat filePath1 filePath2 > filePath_merged

and call ncrack

ncrack -P filePath_merged --user user1,user2,user3 ipAddress:port

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .