Skip to content

Instantly share code, notes, and snippets.

Adam Baldwin evilpacket

Block or report user

Report or block evilpacket

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
@evilpacket
evilpacket / gist:3628941
Created Sep 5, 2012
Top 1000 from Alexa Top 1million
View gist:3628941
wget -q http://s3.amazonaws.com/alexa-static/top-1m.csv.zip;unzip top-1m.csv.zip; awk -F ',' '{print $2}' top-1m.csv|head -1000 > top-1000.txt; rm top-1m.csv*
@evilpacket
evilpacket / gist:3647908
Created Sep 5, 2012
Pure lua MD5 Implementation
View gist:3647908
--[[---------------
LuaBit v0.4
-------------------
a bitwise operation lib for lua.
http://luaforge.net/projects/bit/
How to use:
-------------------
bit.bnot(n) -- bitwise not (~n)
@evilpacket
evilpacket / gist:3924845
Created Oct 20, 2012
Available Lua functions in Redis 2.6
View gist:3924845
_G.__redis__compare_helper()
_G.assert()
_G.collectgarbage()
_G.getfenv()
_G.getmetatable()
_G.newproxy()
_G.next()
_G.pcall()
_G.print()
_G.rawequal()
View gist:3997031
local floor,insert = math.floor, table.insert
local function basen(n,b)
n = floor(n)
if not b or b == 10 then return tostring(n) end
local digits = "0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz"
local t = {}
local sign = ""
if n < 0 then
sign = "-"
n = -n
View rails_rce.rb
#!/usr/bin/env ruby
#
# Proof-of-Concept exploit for Rails Remote Code Execution (CVE-2013-0156)
#
# ## Advisory
#
# https://groups.google.com/forum/#!topic/rubyonrails-security/61bkgvnSGTQ/discussion
#
# ## Caveats
#
View gist:5856305
So on FF 21.0 I set the following header X-Content-Security-Policy I get the following error message in the console.
```
The X-Content-Security-Policy and X-Content-Security-Report-Only headers will be deprecated in the future. Please use the Content-Security-Policy and Content-Security-Report-Only headers with CSP spec compliant syntax instead.
```
If I set the Content-Security-Policy header it does not honor the policy.
Additionally report only does not appear to work at all in FF 21.0
View gist:5937564
>> servo.1373062175128 Board <- Serialport ready /dev/cu.usbmodem1411
string_decoder.js:109
charStr += buffer.toString(this.encoding, 0, end);
^
RangeError: toString() radix argument must be between 2 and 36
at Number.toString (native)
at StringDecoder.write (string_decoder.js:109:21)
at ReadStream.onData (readline.js:833:39)
at ReadStream.EventEmitter.emit (events.js:95:17)
View gist:5937565
var five = require("johnny-five"),
board;
var keypress = require('keypress');
board = new five.Board();
board.on("ready", function() {
console.log( "Ready event. Repl instance auto-initialized" );
var servo = new five.Servo(10)
@evilpacket
evilpacket / letter_freq.json
Created Jul 11, 2013
English letter frequencies in json format
View letter_freq.json
{
"a": 8.167,
"b": 1.492,
"c": 2.782,
"d": 4.253,
"e": 12.702,
"f": 2.228,
"g": 2.015,
"h": 6.094,
"i": 6.966,
View keybase.md

Keybase proof

I hereby claim:

  • I am evilpacket on github.
  • I am adam_baldwin (https://keybase.io/adam_baldwin) on keybase.
  • I have a public key whose fingerprint is 06A7 065F ABC8 39CC 27D3 5E01 D9D0 F356 6734 88E4

To claim this, I am signing this object:

You can’t perform that action at this time.