cr-marcstevens / hashclash

Project HashClash - MD5 & SHA-1 cryptanalysis
Other
742 stars 87 forks source link

Remove remaining references to deprecated variable `data` #13

Closed bmurray7 closed 4 years ago

bmurray7 commented 4 years ago

In d714b7a443991f65be1cd3574d46fa0fee58f82f, the bash variable data was deprecated and replaced with dataupper and datalower. This commit removes the remaining references to data and replaces them with references to either dataupper and datalower.

If the search for differential paths fails, the references to a deprecated variables can results in a syntax error.

if [ ! -s data/bestpath.bin.gz ]; then let data=$((2*$data)); echo "First step failed. Restarting"; sleep 2; continue; fi

./poc_no.sh: line 137: 2*: syntax error: operand expected (error token is "*")
cr-marcstevens commented 4 years ago

Thanks for spotting these minor bugs and for suggesting changes! Actually, the changes for lines L108 and L138 remain buggy and should use: datalower=$((2*$datalower)) If you want you can make these changes and then I'll merge the PR, otherwise I'll pick it up later this week.

cr-marcstevens commented 4 years ago

Thanks!