0 votes

I'm trying to perform a search with this code:

AgentRansack.exe -d "C:\folder_of_interest" -c "/forwardslash" -o "C:\output\file.txt" -oa

This code works fine if I remove the forward slash and turn it into:

 AgentRansack.exe -d "C:\folder_of_interest" -c "noforwardslash" -o "C:\output\file.txt" -oa

I can also search with the forward slash from the GUI just fine.

The error pop-up I get when I try to run the first line of code is

Expecting a value for command line flag '-forwardslah' but none provided

Why does adding a forward slash to the beginning of a string make the command line tool think it's a flag? Is there any way around this?

by (40 points)

1 Answer

+1 vote
 
Best answer

It's a bug in the program. If the first character of a string parameter is a minus sign or forward slash the command line parser incorrectly determines that it is a flag. It'll be fixed soon.

by (30.1k points)
...