This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// cave.idc : An IDA IDC script to find alignment blocks | |
// (also called 'code cave') in an IDA database. | |
// Useful when you need to add code to a binary file | |
// Say for example you found an exploitable bug in a program | |
// and you don't want to wait for the developer to provide a bugfix, | |
// you can add your own code to the alignment block in order to manually | |
// fix the bug. | |
// Code by trapflag | |
// bugfixed by death |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<# : | |
@setlocal disabledelayedexpansion enableextensions | |
@echo off | |
powershell -nol -noni -nop -ex bypass -c "&{[ScriptBlock]::Create((cat '%~f0') -join [Char[]]10).Invoke(@(&{$args}%*))}" | |
exit /b | |
#> | |
Write-Host === CRLF -> LF ===`n | |
$items = dir .\ -recurse | where {$_.extension -in ".sln",".vcproj",".vcxproj",".vcxproj.filters",".md",".cs",".c",".h",".cpp",".inc",".hpp",".txt",".cc",".log",".def",".asm",".mk",".s",".json",".lua",".xml",".ini",".sql",".cfg",".nsh",".nsi",".sma",".php",".sh",".res",".bat",".conf",".js"} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// tada.c | |
// compile (msvc): | |
// cl /MD /O2 /Zl /GS- /kernel /D "WIN32" /D "NDEBUG" /D "_WINDOWS" tada.c /link kernel32.lib winmm.lib /entry:main /subsystem:windows /pdb:none /machine:I386 /nodefaultlib /incremental:no /manifest:no /safeseh:no /emitpogophaseinfo /RELEASE /OPT:REF /OPT:ICF | |
#define WINVER 0x0501 | |
#define _WIN32_WINNT 0x0501 | |
#include <windows.h> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Half-Life / GoldSrc Engine | |
// RCE Fix (Buffer Overflow) | |
// | |
// CVE: CVE-2023-35855 | |
// | |
// Module: hw.dll | |
// Build: Aug 3 2020 (8684) | |
// | |
// Original SHA1 : f0f7372692f285154c76be35fc50b89ed0ea2d18 | |
// Fixed SHA1 : 51c2ecb1ab8241b6afeae535a6a66dbd73a00a65 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
class IDNA { | |
public static function encode($string) { | |
$parts = explode('.', $string); | |
foreach ($parts as &$part) { | |
$part = self::to_ascii($part); | |
if ($part === false) return false; | |
} | |
return implode('.', $parts); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/* Simple PHP WHOIS (PHP >= 4.0) */ | |
/* https://gist.github.com/anzz1 */ | |
/* --------------------- CONFIGURATION --------------------- */ | |
// Clean up comments ('#', '%') and empty lines from the response | |
$NO_COMMENTS = false; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<# : | |
@setlocal disabledelayedexpansion enableextensions | |
@echo off | |
powershell -nol -noni -nop -ex bypass -c "&{[ScriptBlock]::Create((cat '%~f0') -join [Char[]]10).Invoke(@(&{$args}%*))}" | |
exit /b | |
#> | |
function filesize($length) { | |
if($length -gt 1073741824) { | |
"{0:n1} GB" -f ($length / 1073741824) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
ghcommit() { | |
git config user.name "**USERNAME**" && \ | |
git config user.email "**EMAIL**" && \ | |
echo git commit && \ | |
git commit | |
} | |
ghclone-s() { | |
if [ ! -z "$1" ]; then |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# boot2docker v18.01.0-ce 03596f5 Linux 4.4.111-boot2docker x86_64 | |
## config | |
BOX_CPU_COUNT = "2" | |
BOX_RAM_MB = "4096" | |
DOCKER_IMAGE = "anzz1/miyoomini-toolchain:latest" | |
DOCKER_RUN = "/bin/bash" | |
Vagrant.configure("2") do |config| |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Disable vim automatic visual mode on mouse select | |
issue: :set mouse-=a | |
add to ~/.vimrc: set mouse-=a | |
my ~/.vimrc for preserving global defaults and only changing one option: | |
source $VIMRUNTIME/defaults.vim | |
set mouse-=a |
NewerOlder