Skip to content

Instantly share code, notes, and snippets.

BenGardiner /
Last active Jan 2, 2023
jupyter lab workspace for montrehack

Solving Zack Deveau's SNES NSec 2021 Challenges with radare2 and Jupyter Notebooks

Use files in this gist to make your own solve of these fun challenges by zdeveau! The extra challenge is that you must do it using only static analysis in radare2. To make things a bit easier on you we will use Jupyter (Labs) Notebooks.

Install the python (tested with python-3.10) packages you will need (a full tested pip freeze is in requirements.txt also):

pip3 install jupyterlab r2pipe
BenGardiner / a_snes_sequences_writeup.ipynb
Last active Jan 2, 2023
this a writeup for a pair of fun SNES challenges by Zack Deveau, kinda...
View a_snes_sequences_writeup.ipynb
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
View 0 - r2 can signal printing

patat: wrap: true ...

Extracting CAN Signals from OpenXC with Radare2

If you haven't yet: please build and install r2 from git now : git clone; cd radare2 ; ./sys/ And also pip install r2pipe.

Download the target binary file at This is a 'FORDBOARD' vi-firmware device; here's the datasheet for a LPC1768

BenGardiner / Advent Calendar of Advanced Cyber Fun 2018
Last active Dec 27, 2018
Advent Calendar of Advanced Cyber Fun 2018 Writeup
View Advent Calendar of Advanced Cyber Fun 2018

This is a writeup of the solutions to the Advent Calendar of Advanced Cyber Fun 2018. If you're not familiar, this is an advent-themed challenge so there was one new challenge each day from Dec 1st to Dec 24th. The challenges focused on exotic networking features. Usually, successfully connecting would win but sometimes challenge-response was necessary too.

The Advent Calendar of Advanced Cyber Fun 2018 was organized by @_takeshix and @lod108 and a big special thanks to them -- this was a ton of xmas fun!

Port 1

I'll quote the challenge description that they posted on here:

Sometimes it's hard to remember all of those silly port numbers. And there is this restriction of 65535 ports, but santa wanted to host this year's wishlist protocol on TCP 24122018! Wouldn't it be great to access services based on their name, and not their port number?! So Santa is hosting the wishlist service with the help of old school technology: RFC1078. Send him your wishlist!

BenGardiner /
Last active Sep 15, 2017
r2con `antir2` writeup
BenGardiner /
Created May 26, 2017
get @cortesi's byteclass pallete in @FireyFly's pixd -- export PIXD_COLORS="$(./"
#!/usr/bin/env python
import string
import sys
def getPoint(c):
if c == 0:
return [0, 0, 0]
elif c == 255:
return [255, 255, 255]
elif chr(c) in string.printable:
View hterm_solarized.js
// Run in the JavaScript console of the hterm browser window
// Clear all existing settings - you probably don't want to do this.
// Preferences are now stored in "" instead of
// "window.localStorage" so if you clear your preferences the changes
// will be propagated to other devices.
//;;'enable-bold', true);
BenGardiner / dry-run and verbose example
Created Jan 30, 2012
An example of how to do 'verbose' mode and a dry-run mode together
View dry-run and verbose example
function echo_and_exec()
echo "Executing $@" ; "$@"
function set_exec()
if [ -z "${DRYRUN}" ]; then