Skip to content

Instantly share code, notes, and snippets.

View illnyang's full-sized avatar
🪶
blissful

Illyan Garte illnyang

🪶
blissful
  • traversing the 7 seas
View GitHub Profile
@azadkuh
azadkuh / dll2lib.md
Last active February 17, 2023 13:47
extract the *.lib from a *.dll in Win32

extract *.lib from *.dll

do the following steps:

1. exports

extract the functions and classes in *.dll by:
$> dumpbin.exe /exports libsample.dll /out:libsample.def

2. function names

@Cr4sh
Cr4sh / WoW64_call.cpp
Created May 22, 2014 19:33
WoW64 Heaven's Gate
#include "stdafx.h"
#define DB(_val_) __asm __emit (_val_)
#define INVALID_SYSCALL (DWORD)(-1)
// code selectors
#define CS_32 0x23
#define CS_64 0x33
if(GlobalVariable* GA = M.getGlobalVariable("llvm.global.annotations")) {
// the first operand holds the metadata
for (Value *AOp : GA->operands()) {
// all metadata are stored in an array of struct of metadata
if (ConstantArray *CA = dyn_cast<ConstantArray>(AOp)) {
// so iterate over the operands
for (Value *CAOp : CA->operands()) {
// get the struct, which holds a pointer to the annotated function
// as first field, and the annotation as second field
if (ConstantStruct *CS = dyn_cast<ConstantStruct>(CAOp)) {
@Fonger
Fonger / HideModule.cpp
Last active January 5, 2023 04:15
Hide DLL ( 32bit and 64bit support)
#include "stdafx.h"
#include "HideModule.h"
std::vector<UNLINKED_MODULE> UnlinkedModules;
void RelinkModuleToPEB(HMODULE hModule)
{
std::vector<UNLINKED_MODULE>::iterator it = std::find_if(UnlinkedModules.begin(), UnlinkedModules.end(), FindModuleHandle(hModule));
if (it == UnlinkedModules.end())
@wbenny
wbenny / nt_syscalls.md
Last active March 22, 2023 07:59
Windows syscall stubs

Windows system calls

...by stub

x86

Windows XP

B8 ?? ?? ?? ??                mov     eax, ??
BA 00 03 FE 7F                mov     edx, 7FFE0300h
@jult
jult / TLS
Last active December 7, 2020 00:10
My nginx include for TLS A+ rating at ssllabs.com/ssltest using nginx/1.14.* and openssl 1.1.1*
# version 2020 feb 24
ssl_certificate /etc/letsencrypt/live/yardomain.org/fullchain.pem;
ssl_certificate_key /etc/letsencrypt/live/yardomain.org/privkey.pem;
ssl_trusted_certificate /etc/letsencrypt/live/yardomain.org/chain.pem;
ssl_protocols TLSv1.2 TLSv1.3;
ssl_ciphers ECDHE-ECDSA-AES128-GCM-SHA256:ECDHE-RSA-AES128-GCM-SHA256:ECDHE-ECDSA-AES256-GCM-SHA384:ECDHE-RSA-AES256-GCM-SHA384:ECDHE-ECDSA-CHACHA20-POLY1305:ECDHE-RSA-CHACHA20-POLY1305:DHE-RSA-AES128-GCM-SHA256:DHE-RSA-AES256-GCM-SHA384;
ssl_prefer_server_ciphers off;
@shakesoda
shakesoda / imgui_bgfx.cpp
Last active February 17, 2021 19:56
imgui for bgfx (works with unmodified imgui)
#include <imgui/imgui.h>
#include <SDL2/SDL_syswm.h>
#include "myon/imgui.hpp"
#include "myon/window.hpp"
#include "myon/timer.hpp"
#include "myon/cache.hpp"
#include "math/matrix.hpp"
#include <bgfx/bgfx.h>
#include <imgui/imgui_demo.cpp>
#include <imgui/imgui_lua_bindings.cpp>
@zingmars
zingmars / tinc.MD
Last active March 14, 2024 12:02
tinc VPN setup instructions on Windows and Linux

Tinc setup instructions for Ubuntu and Windows. Based on 1 2.

Start here.

  1. sudo apt-get install -y build-essential libncurses5-dev libreadline6-dev libzlcore-dev zlib1g-dev liblzo2-dev libssl-dev
  2. Download and install tinc
    2.1. Download the latest tinc 1.1 source package ( current: wget https://www.tinc-vpn.org/packages/tinc-1.1pre16.tar.gz -O tinc.tar.gz)
    • tar -xf tinc.tar.gz --one-top-level --strip-components=1
    • cd tinc
    • ./configure
@niklas-ourmachinery
niklas-ourmachinery / reducing-build-times.md
Created January 24, 2019 16:30
Reducing build times by 20 % with a one line change

Reducing build times by 20 % with a one line change

Experimenting a bit with the /d2cgsummary and /d1reportTime flags described by Aras here and here I noticed that one of our functions was consistently showing up in the Anomalistic Compile Times section:

1>	Anomalistic Compile Times: 2
1>		create_truth_types: 0.643 sec, 2565 instrs
1>		draw_nodes: 0.180 sec, 5348 instrs
All albums uploaded to the /jp/ denpa thread since June 2018.
IF A LINK IS DEAD PLEASE CHECK THE LINKS HERE FIRST: https://gist.github.com/dnpcllctns/9424fcc4c80429253d3194251b4a15ed
If it's not there/not available then comment and let me know!
For uploads 2016 - 2018 see https://nyaa.si/view/1068471 or https://gist.github.com/dnpcllctns/9424fcc4c80429253d3194251b4a15ed
June - December 2018:
妄想の旅団 - 古代アイドル!黄泉比良坂88! (FLAC) - https://mega.nz/#F!W8UUVSwJ!1H_Y1fn55w-PqFqP0UUy-g
妄想の旅団 - ゆりゆりやんもえフィーバー (FLAC) - https://mega.nz/#F!ihFCCS7L!0fN-sPmjfW1r76DSW_EQ8w
シルクパラソル collection- https://mega.nz/#F!K91hzIqS!PPuzfXX0neFufLV5-le6Ww
とろ美 ‐ ねぎとろ美 - https://mega.nz/#!qgE01IjJ!C4IV1FwCy81ZqYpRM_AUx1mDeQIag1HvlWjdPyNHJxk