Skip to content

Instantly share code, notes, and snippets.


Lin, Yong Xiang r888800009

View GitHub Profile
vjt /
Last active Sep 29, 2021
Copy data from a Time Machine volume mounted on a Linux box.
# Copy data from a Time Machine volume mounted on a Linux box.
# Usage: <source> <target>
# source: the source directory inside a time machine backup
# target: the target directory in which to copy the reconstructed
# directory trees. Created if it does not exists.
sckalath / linux_privesc
Last active Oct 4, 2021
Linux Privilege Escalation Techniques
View linux_privesc
// Determine linux distribution and version
cat /etc/issue
cat /etc/*-release
cat /etc/lsb-release
cat /etc/redhat-release
// Determine kernel version - 32 or 64-bit?
cat /proc/version
uname -a
uname -mrs
2xAA / iterm-colors-to-vscode.js
Last active Nov 4, 2021
Convert iTerm2 "itermcolors" file to VSCode terminal color scheme
View iterm-colors-to-vscode.js
/* Generate colors using */
const col = [] // run your .itermcolors file through the above parser and replace the array with the output
function componentToHex(c) {
const hex = c.toString(16)
return hex.length === 1 ? `0${hex}` : hex
const mapping = {
'terminal.background':'Background Color',
sourcerebels /
Created Feb 20, 2012
Download all Phrack Magazine Issues
for i in {1..67}
tar xvzf ${FILE}
rm ${FILE}
crunchprank /
Created Dec 15, 2015
Cheat Sheet For Password Crackers

Cheat Sheet For Password Crackers

This list was posted over at Unix-Ninja. I take no credit for these. Posting these here for my own convenience.

Extracting Data

Extract md5 hashes

# egrep -oE '(^|[^a-fA-F0-9])[a-fA-F0-9]{32}([^a-fA-F0-9]|$)' *.txt | egrep -o '[a-fA-F0-9]{32}' > md5-hashes.txt
# egrep -oE '(^|[^a-fA-F0-9])[a-fA-F0-9]{32}([^a-fA-F0-9]|$)' *.txt | egrep -o '[a-fA-F0-9]{32}' > md5-hashes.txt
View peParser.cpp
#include <windows.h>
#include <iostream>
bool readBinFile(const char fileName[], char*& bufPtr, DWORD& length) {
if (FILE* fp = fopen(fileName, "rb")) {
fseek(fp, 0, SEEK_END);
length = ftell(fp);
bufPtr = new char[length + 1];
fseek(fp, 0, SEEK_SET);
fread(bufPtr, sizeof(char), length, fp);
ccwang002 /
Last active Dec 7, 2021
Lab Coding Instructions for Beginners


Lab Guide for Coding Beginners

亮亮(@ccwang002)| Mar, 2015 | CC 3.0 BY license

如果內容有誤,你可以用任何管道發訊息轟炸我,或用底下的 gist comment 留言。



mzabriskie /
Last active Dec 8, 2021
Check git status of multiple repos

If you're like me you have a dir like ~/Workspace/Github where all your git repos live. I often find myself making a change in a repo, getting side tracked and ending up in another repo, or off doing something else all together. After a while I end up with several repos with modifications. This script helps me pick up where I left off by checking the status of all my repos, instead of having to check each one individually.


git-status [directory]

This will run git status on each repo under the directory specified. If called with no directory provided it will default to the current directory.

rodneyrehm / gist:40e7946c0cff68a31cea
Last active Dec 11, 2021
Diagrams for Documentation
View gist:40e7946c0cff68a31cea

some tools for diagrams in software documentation

Diagrams For Documentation

Obvious Choices