Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Including file hash in command line profiling #193

Closed
timrdf opened this issue Nov 21, 2017 · 1 comment
Closed

Including file hash in command line profiling #193

timrdf opened this issue Nov 21, 2017 · 1 comment
Labels

Comments

@timrdf
Copy link

timrdf commented Nov 21, 2017

I've managed to follow ./droid.sh --help to create a profile and then export it to CSV and XML:

bash-3.2$ ./droid.sh -a `pwd`/droid-command-line-6.4.jar -p my.droid
bash-3.2$ ./droid.sh -p my.droid -e "my.droid.csv"
bash-3.2$ grep PUID my.droid.csv 
"ID","PARENT_ID","URI","FILE_PATH","NAME","METHOD","STATUS","SIZE","TYPE","EXT","LAST_MODIFIED","EXTENSION_MISMATCH","HASH","FORMAT_COUNT","PUID","MIME_TYPE","FORMAT_NAME","FORMAT_VERSION"
bash-3.2$ ./droid.sh -p my.droid -n "Comprehensive breakdown" -r "my.droid.xml" -t "DROID Report XML"
bash-3.2$ grep '<Name>' my.droid.xml | grep droid
                        <Name>droid-command-line-6.4.jar</Name>

Unfortunately, the CSV's "HASH" column is empty and the XML's <GenerateHash>false</GenerateHash> element indicates that it also did not gather the file hash.

Is there a way to enable file hashing from the command line?

Thanks,
Tim

@paulyoung84
Copy link

Hi Tim,

I'm sorry for the late response. Unfortunately there is no way when creating the .droid file to specify hashing in the cmd. You can run the GUI and change the preferences there to the type of hash you want to generate, this change will alter the settings in the droid.properties file which will then be set for the cmd line as well.

Alternatively you could edit the droid.properties file directly, it is in the .droid6 folder in your user directory. For me this is C:\Users\pyoung.droid6\droid.properties. In this file if you change 'profile.generateHash' to 'true' this will turn hashing on, in 'profile.hashAlgorithm' you can specify the type of hash you want to generate it defaults to 'md5' but you can also do 'sha256' or 'sha1'.

Best,

Paul

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

4 participants