thenuke321

Untitled

Dec 4th, 2015
170
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 1.81 KB | None | 0 0
  1. #include <windows.h>
  2. #include <string>
  3.  
  4. using namespace std;
  5.     HINSTANCE hinstDLL;
  6.     typedef void(*blockXorF)(string&,string);
  7.     typedef void(*teaEncodeF)(string,string,string&);
  8.     typedef void(*teaDecodeF)(string,string,string&);
  9.     typedef void(*md5F)(string&);
  10.     typedef void(*sha512F)(string&);
  11.     typedef void(*fileReadF)(string,string&);
  12.     typedef void(*writeFileF)(string,string);
  13.     typedef void(*rc4EncodeF)(string,string,string&);
  14.     typedef void(*rc4DecodeF)(string,string,string&);
  15.     typedef void(*toBase64F)(string,string&);
  16.     typedef void(*fromBase64F)(string,string&);
  17.     typedef void(*aesFileF)(string,string,string,string);
  18.     //  File Cypher
  19.  
  20.     // Cypher
  21.     blockXorF blockXor(0);
  22.     teaEncodeF teaEncode(0);
  23.     teaDecodeF teaDecode(0);
  24.     rc4EncodeF rc4Encode(0);
  25.     rc4DecodeF rc4Decode(0);
  26.  
  27.     // Hash
  28.     md5F md5(0);
  29.     sha512F sha512(0);
  30.     // File functions
  31.     fileReadF fileRead(0);
  32.     writeFileF fileWrite(0);
  33.     aesFileF aesFile(0);   
  34.     // Base64
  35.     toBase64F toBase64(0);
  36.     fromBase64F fromBase64(0);
  37. void load()
  38. {
  39.     hinstDLL = LoadLibrary("adevlib.dll");
  40.     fileRead = (fileReadF)GetProcAddress(hinstDLL,"fileRead"); 
  41.     fileWrite = (writeFileF)GetProcAddress(hinstDLL,"fileWrite");  
  42.     teaEncode = (teaEncodeF)GetProcAddress(hinstDLL,"teaEncode");
  43.     teaDecode = (teaDecodeF)GetProcAddress(hinstDLL,"teaDecode");
  44.     rc4Encode = (rc4EncodeF)GetProcAddress(hinstDLL,"rc4Encode");
  45.     rc4Decode = (rc4DecodeF)GetProcAddress(hinstDLL,"rc4Decode");
  46.     blockXor = (blockXorF)GetProcAddress(hinstDLL,"blockXor");
  47.     aesFile = (aesFileF)GetProcAddress(hinstDLL,"aesFile");
  48.     md5 = (md5F)GetProcAddress(hinstDLL,"md5");
  49.     sha512 = (sha512F)GetProcAddress(hinstDLL,"sha512");
  50.     toBase64 = (toBase64F)GetProcAddress(hinstDLL,"toBase64");
  51.     fromBase64 = (fromBase64F)GetProcAddress(hinstDLL,"fromBase64");
  52. }
  53.  
  54. void breakDLL()
  55. {
  56.     FreeLibrary(hinstDLL);
  57. }
Advertisement
Add Comment
Please, Sign In to add comment