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/bash | |
# | |
# DESCRIPTION: | |
# | |
# Set the bash prompt according to: | |
# * the active virtualenv | |
# * the branch/status of the current git repository | |
# * the return value of the previous command | |
# * the fact you just came from Windows and are used to having newlines in | |
# your prompts. |
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
from Crypto.Cipher import AES | |
from StringIO import StringIO | |
from bplist import BPlistReader #https://github.com/farcaller/bplist-python | |
import M2Crypto | |
import gzip | |
import struct | |
def xor_strings(s, key): | |
res = "" | |
for i in xrange(len(s)): |
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
# Solarized Theme | |
# Attempting to copy: http://ethanschoonover.com/solarized | |
# Example: http://i.imgur.com/T9BTRG4.png | |
if patched_font_in_use; then | |
TMUX_POWERLINE_SEPARATOR_LEFT_BOLD="⮂" | |
TMUX_POWERLINE_SEPARATOR_LEFT_THIN="⮃" | |
TMUX_POWERLINE_SEPARATOR_RIGHT_BOLD="⮀" | |
TMUX_POWERLINE_SEPARATOR_RIGHT_THIN="⮁" | |
else |
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
<? | |
/* | |
popfinder.php - Emilio Pinna 2013 | |
Popfinder is a simple script that can helps code analysis of PHP in case of possible object | |
injection[1][2] in unserialize function. |
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
# | |
# Very simple script that uses birthday paradox to find collision for hash function H(x) | |
# that truncates the output of SHA-256(x) to 50 bits. Written for cryptography class. | |
# See [Stinson, 2005] for why this works. | |
# | |
import hashlib | |
import os | |
import binascii |
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
jQuery.base64 = (function($) { | |
// private property | |
var keyStr = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/="; | |
// private method for UTF-8 encoding | |
function utf8Encode(string) { | |
string = string.replace(/\r\n/g,"\n"); | |
var utftext = ""; | |
for (var n = 0; n < string.length; n++) { |
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/bash | |
sudo kextunload -b com.apple.iokit.BroadcomBluetoothHostControllerUSBTransport | |
sudo kextload -b com.apple.iokit.BroadcomBluetoothHostControllerUSBTransport |
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
require('tap-browser-color')(); | |
var test = require('tape'); | |
test('it flattens!', function(t) { | |
var input = { | |
users: [ | |
{ name: 'name1', id: 1, image: { '64x64': 'http://1' } }, | |
{ name: 'name2', id: 2, image: { '64x64': 'http://2' } } | |
], | |
errors: [ new Error('err1') ], |
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
find . -type d -name '.git' | while read dir ; do sh -c "cd $dir/../ && echo -e \"\nGIT STATUS IN ${dir//\.git/}\" && git status -s" ; done |
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
# firsrun: | |
# install xcode-cli-tools | |
# xcode-select --install | |
# install homebrew | |
# ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)" | |
# install caskroom | |
# brew install caskroom/cask/brew-cask | |
# update/install: |
OlderNewer