Skip to content

Instantly share code, notes, and snippets.

Tanner Prynn tprynn

Block or report user

Report or block tprynn

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
@tprynn
tprynn / util.js
Last active May 31, 2019
Frida utility functions
View util.js
module.exports = {
hexStringToIntArray: function(str) {
var res = []
for(var i = 0; i < str.length; i += 2) {
res.push(parseInt(str.substring(i, i+2), 16))
}
return res
},
byteArrayToHexString: function(array) {
View setuidgid.b64
f0VMRgIBAQAAAAAAAAAAAAIAPgABAAAAsARAAAAAAABAAAAAAAAAALgKAAAAAAAAAAAAAEAAOAAIAEAAHAAbAAYAAAAFAAAAQAAAAAAAAABAAEAAAAAAAEAAQAAAAAAAwAEAAAAAAADAAQAAAAAAAAgAAAAAAAAAAwAAAAQAAAAAAgAAAAAAAAACQAAAAAAAAAJAAAAAAAAcAAAAAAAAABwAAAAAAAAAAQAAAAAAAAABAAAABQAAAAAAAAAAAAAAAABAAAAAAAAAAEAAAAAAAFwHAAAAAAAAXAcAAAAAAAAAACAAAAAAAAEAAAAGAAAAYAcAAAAAAABgB2AAAAAAAGAHYAAAAAAAKAIAAAAAAAAwAgAAAAAAAAAAIAAAAAAAAgAAAAYAAAB4BwAAAAAAAHgHYAAAAAAAeAdgAAAAAADQAQAAAAAAANABAAAAAAAACAAAAAAAAAAEAAAABAAAABwCAAAAAAAAHAJAAAAAAAAcAkAAAAAAAEQAAAAAAAAARAAAAAAAAAAEAAAAAAAAAFDldGQEAAAAOAYAAAAAAAA4BkAAAAAAADgGQAAAAAAANAAAAAAAAAA0AAAAAAAAAAQAAAAAAAAAUeV0ZAYAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAEAAAAAAAAAAvbGliNjQvbGQtbGludXgteDg2LTY0LnNvLjIABAAAABAAAAABAAAAR05VAAAAAAACAAAABgAAACAAAAAEAAAAFAAAAAMAAABHTlUA9Il3qGrQRKItg7lrcUo3xLlmyI4BAAAAAQAAAAEAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABIAAAASAAAAAAAAAAAAAAAAAAAAAAAAACAAAAASAAAAAAAAAAAAAAAAAAAAAAAAADIAAAAgAAAAAAAAAAAAAAAAAAAAAAAAABkAAAASAAAAAAAAAAAAAAAAAAAAAAAAAAsAAAASAAAA
@tprynn
tprynn / linuxprivchecker.py
Last active Dec 24, 2018
removed some unnecessarily verbose checks
View linuxprivchecker.py
#!/usr/env python
###############################################################################################################
## [Title]: linuxprivchecker.py -- a Linux Privilege Escalation Check Script
## [Author]: Mike Czumak (T_v3rn1x) -- @SecuritySift
##-------------------------------------------------------------------------------------------------------------
## [Details]:
## This script is intended to be executed locally on a Linux box to enumerate basic system info and
## search for common privilege escalation vectors such as world writable files, misconfigurations, clear-text
## passwords and applicable exploits.
@tprynn
tprynn / ssls.md
Last active Dec 2, 2018
List of libraries implementing SSL/TLS
View ssls.md

List of libraries implementing SSL/TLS

Generic OpenSSL replacement

  • LibreSSL
  • BearSSL

Embedded

  • mbedTLS (PolarSSL)
  • MatrixSSL
@tprynn
tprynn / curve25519.rb
Created May 25, 2015
ECDHE + Curve25519 academic implementation in Ruby
View curve25519.rb
# Curve25519+ECDH implementation in Ruby
# Disclaimer: This code is for learning purposes ONLY. It is NOT secure.
# Tanner Prynn
require 'SecureRandom'
require 'digest'
# Fast Modular Exponentiation (base**exp % mod)
def modexp(base, exp, mod)
prod = 1
@tprynn
tprynn / md4.rb
Created Aug 6, 2014
Ruby md4 implementation
View md4.rb
def md4(string)
# functions
mask = (1 << 32) - 1
f = proc {|x, y, z| x & y | x.^(mask) & z}
g = proc {|x, y, z| x & y | x & z | y & z}
h = proc {|x, y, z| x ^ y ^ z}
r = proc {|v, s| (v << s).&(mask) | (v.&(mask) >> (32 - s))}
# initial hash
a, b, c, d = 0x67452301, 0xefcdab89, 0x98badcfe, 0x10325476
@tprynn
tprynn / sha1.rb
Created Aug 6, 2014
Ruby sha1 implementation
View sha1.rb
def sha1(string)
# functions and constants
mask = 0xffffffff
s = proc{|n, x| ((x << n) & mask) | (x >> (32 - n))}
f = [
proc {|b, c, d| (b & c) | (b.^(mask) & d)},
proc {|b, c, d| b ^ c ^ d},
proc {|b, c, d| (b & c) | (b & d) | (c & d)},
proc {|b, c, d| b ^ c ^ d},
].freeze
View stOnOffHello.ino
/**********
* SmartThings Arduino Shield On/Off
* For use on Arduino Mega
* author: github.com/tprynn
* Attach Shield normally with switch on 2/3.
* Jumper pins:
* - 18 (Tx1) to Shield 3 (Rx)
* - 19 (Rx1) to Shield 2 (Tx)
**********/
View stPassthru.ino
/**********
* SmartThings Arduino Shield Passthrough
* For use on Arduino Mega
* author: github.com/tprynn
* Attach Shield normally with switch on 2/3.
* Jumper pins:
* - 18 (Tx1) to Shield 3 (Rx)
* - 19 (Rx1) to Shield 2 (Tx)
**********/
View communities.pde
/* ISTA 303 Assignment 1
* Tanner Prynn
* communities.pde
* Implements a signal-passing automata based on a random graph.
* Some notes:
* - Nodes are connected according to their relative distances.
* - Communication between nodes in the same community is shown in green,
* communication between different communities is shown in red.
* - Nodes are more likely to communicate within their own communities.
* - Messages spread outward from their origination point.
You can’t perform that action at this time.