This file contains 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
#include <stdio.h> | |
#include <stdint.h> | |
#include <stdlib.h> | |
#include <stdbool.h> | |
#include <string.h> | |
#define NICKNAMED(x) ((x & 0x80000000) >> 31) | |
#define IS_EGG(x) ((x & 0x40000000) >> 30) | |
#define SP_DEF_IV(x) ((x & 0x3e000000) >> 25) | |
#define SP_ATT_IV(x) ((x & 0x01f00000) >> 20) |
This file contains 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
#!/usr/bin/env ruby | |
INPUT_FILE = 'part_one.input' | |
View = Data.define(:r, :g, :b) do | |
REGEX = /(\d+) red|(\d+) green|(\d+) blue/ | |
def total = r + g + b | |
def power = r * g * b | |
def +(o) = self.class[r + o.r, g + o.g, b + o.b] |
This file contains 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
#!/usr/bin/env ruby | |
input = File.read('day_one.input') | |
Token = Data.define(:forward, :backward) | |
Tokens = { | |
eightwo: Token[8, 2], | |
eighthree: Token[8, 3], | |
fiveight: Token[5, 8], | |
nineight: Token[9, 8], |
This file contains 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
#include <iostream> | |
#include <complex> | |
#define PI 3.141592653589793 | |
#define SAMPLE_RATE 64 | |
using namespace std; | |
// This lowpass is a weighted moving average | |
// If you change the + to - it will become a highpass filter |
This file contains 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
#!/usr/bin/env ruby | |
require 'csv' | |
require 'socket' | |
require 'tempfile' | |
IP = '192.168.0.24' | |
PORT = 5555 | |
class Screenshot |
This file contains 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 | |
LIMIT='100' | |
SLEEP='1' | |
TOKEN='xxxxxxx-xxxxxxxxxxxxxxxxxx-xxxx-xxxxxx' | |
USERNAME='username' | |
# Delete a comment by id | |
function delete_comment() { |
This file contains 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
#!/usr/bin/env python | |
from pwn import * | |
context(arch='amd64', log_level='info') | |
if len(sys.argv) >= 2: | |
use_one_gadget = True | |
libc_so_filename = './libc-2.23.so' | |
print("Using libc %s" % libc_so_filename) |
This file contains 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
#!/usr/bin/env ruby | |
require 'base64' | |
require 'json' | |
require 'zlib' | |
# Requirements: | |
# Debian: apt-get install zbar-tools | |
# OSX: brew install zbar |
This file contains 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
#!/usr/bin/env ruby | |
require 'uri' | |
require 'net/http' | |
require 'json' | |
Url = 'http://hackback:6666/netstat' | |
puts "Grabbing #{Url}" | |
uri = URI.parse(Url) |
This file contains 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
#!/usr/bin/env ruby | |
require 'base32' | |
require 'openssl' | |
# Script to calculate HOTP so I don't have to use my phone | |
class HOTP | |
def initialize(original_secret, counter = 0) | |
secret = Base32.decode(original_secret) |
NewerOlder