Skip to content

Instantly share code, notes, and snippets.

View jedisct1's full-sized avatar

Frank Denis jedisct1

View GitHub Profile
@jedisct1
jedisct1 / get_locky.py
Created June 24, 2016 21:25 — forked from mak/get_locky.py
locky sample downloader
import sys
import hashlib
import struct
import requests
def decode(data,seed,step):
r = []
k = seed
for c in map(ord,data):
r.append(chr(c ^ k))
* Install VPS with Debian/Archinux/whatever you're comfortable with
* Get the bsd.rd file and put it in / for instance
wget ftp://ftp.openbsd.org/pub/OpenBSD/5.8/amd64/bsd.rd
* Add something along these lines in your grub.cfg (or /etc/grub.d/40_custom)
Make sure you adapt the (hd0,1) line to your config
menuentry "OpenBSD installer" {
set root=(hd0,1)
kopenbsd /bsd.rd
}
* Update the main grub.cfg:
@jedisct1
jedisct1 / springer-free-maths-books.md
Created December 28, 2015 22:25 — forked from bishboria/springer-free-maths-books.md
Springer have made a bunch of maths books available for free, here are the direct links
@jedisct1
jedisct1 / mingw-on-osx.sh
Last active August 29, 2015 14:24 — forked from Drakulix/mingw-w64-3.10-osx10.9.sh
Install a Windows cross-compiler on OSX
#!/bin/sh
PREFIX="/usr/local/mingw"
BINUTILS_VERSION=2.25
GCC_VERSION=5.1.0
GCC_SUFFIX_VERSION=5.1
MINGW_VERSION=4.0.2
SHA256_SUM=yolo
# check_error my_cmd --param ...
#!/bin/sh
remove_dangling() {
echo "Removing dangling images ..."
docker rmi $(docker images -f dangling=true -q)
}
remove_stopped_containers() {
echo "Removing stopped containers ..."
docker rm $(docker ps -qa)
aperture-2:~ alexcp$ curl --referer http://www.google.com http://www.cdn777.net/adm/login.php?l=1
<html>
<body>
<head>
<style>
#frmstyle { width:0px; height:0px; } 
</style>
</head>
@jedisct1
jedisct1 / latency.txt
Created July 8, 2012 04:18 — forked from h2oai/latency.txt
Latency numbers every programmer should know
L1 cache reference 0.5 ns
Branch mispredict 5 ns
L2 cache reference 7 ns 14x L1 cache
Mutex lock/unlock 25 ns
Main memory reference 100 ns 20x L2 cache, 200x L1 cache
Compress 1K bytes with Zippy 3,000 ns
Send 1K bytes over 1 Gbps network 10,000 ns 0.01 ms
Read 4K randomly from SSD 150,000 ns 0.15 ms
Read 1 MB sequentially from memory 250,000 ns 0.25 ms
Round trip within same datacenter 500,000 ns 0.5 ms