Skip to content

Instantly share code, notes, and snippets.

View dennisfischer's full-sized avatar

Dennis Fischer dennisfischer

View GitHub Profile
@dennisfischer
dennisfischer / testProject.cpp
Created October 31, 2015 14:21
Deny access from outside on VM operations + DUP_HANDLE
// testProject.cpp : Defines the entry point for the console application.
//
#include "stdafx.h"
//Source @http://www.experts-exchange.com/Programming/Microsoft_Development/Q_27484672.html
int main()
{
@dennisfischer
dennisfischer / tls-callback.cpp
Created October 7, 2015 14:53
TLS callback for x86 & x64 windows OS.
// @source: http://www.unknowncheats.me/forum/c-and-c/84146-tls-callback-tutorial.html
#include "windows.h"
#include <stdio.h>
void NTAPI __stdcall TLSCallbacks(PVOID DllHandle, DWORD dwReason, PVOID Reserved);
//linker spec
#ifdef _M_IX86
#pragma comment (linker, "/INCLUDE:__tls_used")
#pragma comment (linker, "/INCLUDE:__tls_callback")
#else