Sign in to follow this  
Followers 0
BlazerV60

From MD5 Hash back to Normal F

4 posts in this topic

#1 ·  Posted (edited)

So I have this code which outputs my file, "BrianProject.au3" as hashcode.

How can I turn this hashcode back into the file name?

#include <Crypt.au3>

 $dHash = _Crypt_HashFile("C:\Users\Brian\Documents\AutoItScripts\BrianProject.au3", $CALG_MD5)
 ConsoleWrite($dHash)

To clarify what I mean: I'm able to turn BrianProject.au3 into 0xt3opagjwihgw38gihwow4w (totally made that up).

Now am I able to turn 0xt3opagjwihgw38gihwow4w back into something that outputs "BrianProject.au3"?

Thanks

Edited by BlazerV60

Share this post


Link to post
Share on other sites



Hopefully not! The actual purpose of any hash algorithm is to implement a one-way "function", which can't be inverted by any known mean. I put function in quotes since it's very hard to formally prove that there is at least one input for every possible resulting hash. But what we can be sure of is that there exist an infinity of inputs which all result in any given hash. This makes it impossible to decide which input was actually used, especially since it is extremely hard if not plain impossible to find an input corresponding to a given hash.

2 people like this

This wonderful site allows debugging and testing regular expressions (many flavors available). An absolute must have in your bookmarks.
Another excellent RegExp tutorial. Don't forget downloading your copy of up-to-date pcretest.exe and pcregrep.exe here
RegExp tutorial: enough to get started
PCRE v8.33 regexp documentation latest available release and currently implemented in AutoIt beta.

SQLitespeed is another feature-rich premier SQLite manager (includes import/export). Well worth a try.
SQLite Expert (freeware Personal Edition or payware Pro version) is a very useful SQLite database manager.
An excellent eBook covering almost every aspect of SQLite3: a must-read for anyone doing serious work.
SQL tutorial (covers "generic" SQL, but most of it applies to SQLite as well)
A work-in-progress SQLite3 tutorial. Don't miss other LxyzTHW pages!
SQLite official website with full documentation (may be newer than the SQLite library that comes standard with AutoIt)

Share this post


Link to post
Share on other sites

I think you are mixing hash with encryption. (Hash is one way, encrypt you can reverse back to its original state)

Share this post


Link to post
Share on other sites

I think you are mixing hash with encryption. (Hash is one way, encrypt you can reverse back to its original state)

Just like Geir1983 said.

Only way using hash is to compare one hash key to another, thats it.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0