The program opens your wordlist file and reads through it line by line and outputs the plaintext hash pairs to a new file. Once again probably the shittiest possible use of command line arguments. But it works.
//Simple example that converts a wordlist from plaintext to plaintext and hash pair tab delimited.
#include <string>
#include <sstream>
#include <iostream>
#include <cctype>
#include <fstream>
#include "md5.h"
#include <cstring>
using namespace std;
int main (int argc, char* argv[2])
{ofstream myfile;
myfile.open (argv[2]);
{ string line; ifstream infile (argv[1]);
if (infile.is_open())
{ while ( getline (infile,line) )
myfile << md5(line) << endl;
cout << line << endl;
string t = md5(line);
cout << t << endl;
}
else cout << "Unable to open file" << endl;
}
return 0; }
No comments:
Post a Comment