Random Code
This repository contains most of the code that I write for my blog posts. I
realized I have random repositories on Github. I am consolidating them into one.
Individual Licenses
Most code in this repository is governed under the MIT. Some
code may have a different license, check each directory for a license file.
Security Code
Security code will be mostly in
https://github.com/parsiya/Go-Security.
Code Index
This table will help but may not be current. Look inside each individual
directory to see the code.
Code for my set of WinAppDbg tutorials.
- Copy the
winappdbg
directory to your Virtual Machine.
- Install Python, WinAppDbg and other software using instructions in part 1.
- Follow the tutorials and enjoy.
- If code is wrong, make an issue here or yell at me on Twitter/email/etc.
Proof of Concepts
See the blog at
https://parsiya.net/blog/2021-vscode-wsl-rce/.
Also exists in https://github.com/parsiya/code-wsl-rce.
Semgrep
Practice rules and code for the blog
A Hands-On Intro to Semgrep's Autofix.
Go
Go is dope, also see https://github.com/parsiya/Go-Security.
Doing the Cryptopals challenges with lol no generics
.
Gophercises by Jon Calhoun.
Code for blog post Blackfriday's Parser and Generating graphs with gographviz.
Code for blog post Windows Filetime Timestamps and Byte Wrangling with Go.
Code for blog post filepath.Ext Notes.
See the write-up at:
Files:
decrypt.go
: Decrypts the password vault.
cleaned-malware.ps1
: Cleaned version of the PowerShell malware.
Python
Small proxy that I wrote for proxying Hipchat.
- Main blog post
- Related blogs:
Small text adventure written in Python using PAWS (Python Adventure Writing
System). Created as part of the class activity for "Advanced Topics in Computer
Security" in 2013 at Johns Hopkins.
PAWS 2.1 is a fork by Matthias C. Hormann
at
https://github.com/Moonbase59/PAWS. PAWS was originally created
by Roger Plowman
.
- Blog post
- Github repository (because there are links to it)
Code for the blog post
Customizing Python's SimpleHTTPServer.
A few python scripts to extract information from pcap files to csv.
Code and example program used in:
Rust
Fearless Concurrency.
Code for the blog post YAML Wrangling with Rust.
Burp
Mostly Burp extension code.
Code and example program used in:
Code used in:
Swing in Python Burp Extensions
- Part 1 blog: Swing in Python Burp Extensions - Part 1
- Part 2 blog:
Code used in:
Sample code to learn how to interact with a SQLite database in Java with
org.xerial.sqlite-jdbc
.
Cryptography
Doing the first few cryptopals challenges in C (why?!).
This code decrypts an application's logs. It uses the Mersenne Twister Engine
with a specific seed to create a key stream. See the blog post at:
A couple of PowerShell scripts that use the Windows DNS cache to discover application endpoints.
This is a fork of the Octopress Image Popup Plugin at
https://github.com/ctdk/octopress-image-popup by Jeremy
Bingham. The original instructions did not work for me out of the box so I made
some minor changes. Because it has a different license, I am keeping it in a
separate repository.
I found this code in an old archive. It's some calculator I wrote back in
undergrad. It draws shapes on the screen and depending on where you click, you
get a number. Pretty much all of it was done manually. The only thing I
remember, is that I needed to have C:\\egavga.bgi
for it to work. Fun times.