所以我有这个exe哈希生成器,我必须找到生成给定特定哈希的字符串。因为我知道字符串的长度,我想知道也许我可以强制输入到可执行文件中。或者也可以有人告诉我如何对整个exe进行逆向工程以找出它是如何生成哈希的。
答案 0 :(得分:1)
您可以编写自定义程序来生成要测试的字符串(C#)
using System;
using System.IO;
namespace ConsoleApplication1
{
class Program
{
static void Main(string[] args)
{
using (StreamWriter sw = new StreamWriter(@"C:\temp\keys.txt"))
{
for (int i = 0; i < 100; i++)
{
// Replace this line by the string you want to test
var str = Guid.NewGuid();
Console.WriteLine(str);
sw.WriteLine(str);
}
}
}
}
}
然后,使用命令重定向将该控制台App的输出重定向到您的EXE文件。 (请参阅https://www.microsoft.com/resources/documentation/windows/xp/all/proddocs/en-us/redirection.mspx?mfr=true)如果您想保留结果,请不要忘记将您的exe输出重定向到文本文件
consoleAppCs.exe | YourExe.exe > "C:\temp\output.txt"
然后您将在c:\temp\
文件夹