jessekornblum ([info]jessekornblum) wrote,
@ 2009-01-15 18:06:00
Previous Entry  Add to memories!  Tell a Friend  Next Entry
Entry tags:fuzzy hashing, hacking

Using Fuzzy Hashing from C#
Recently ssdeep user Jose Cintron wanted to use fuzzy hashing in a C# program. After some significant head scratching he came up with the following code necessary to use at least part of the DLL from his program:

using System.Runtime.InteropServices;	// Needed for DllImport

public class ssdeepWrapper
{
     // fuzzy.dll should be somewhere in the path or specify exactly
     // where to find it.
     [DllImport("fuzzy.dll")]
         public static extern int fuzzy_hash_filename(string fname, 
StringBuilder result);
     [DllImport("fuzzy.dll")]
         public static extern int fuzzy_compare(string sig1, string sig2);
}
Any thoughts? Has anybody else tried using fuzzy hashing from a different language?



Create an Account
Forgot your login or password?
Login w/ OpenID
English • Español • Deutsch • Русский…