{"id":20261330,"url":"https://github.com/parsiya/parsia-code","last_synced_at":"2026-04-20T13:07:50.834Z","repository":{"id":38286850,"uuid":"148045071","full_name":"parsiya/Parsia-Code","owner":"parsiya","description":"Contains random code and some of my older projects","archived":false,"fork":false,"pushed_at":"2024-02-28T04:43:02.000Z","size":2813,"stargazers_count":28,"open_issues_count":0,"forks_count":12,"subscribers_count":3,"default_branch":"master","last_synced_at":"2025-03-03T18:49:24.902Z","etag":null,"topics":["code","go","python","security"],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/parsiya.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2018-09-09T16:39:57.000Z","updated_at":"2024-09-27T09:58:14.000Z","dependencies_parsed_at":"2024-06-19T04:08:01.741Z","dependency_job_id":"d11b5fb1-ab22-4399-ade6-732eed85db66","html_url":"https://github.com/parsiya/Parsia-Code","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/parsiya/Parsia-Code","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/parsiya%2FParsia-Code","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/parsiya%2FParsia-Code/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/parsiya%2FParsia-Code/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/parsiya%2FParsia-Code/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/parsiya","download_url":"https://codeload.github.com/parsiya/Parsia-Code/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/parsiya%2FParsia-Code/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":260124097,"owners_count":22962207,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["code","go","python","security"],"created_at":"2024-11-14T11:25:16.879Z","updated_at":"2026-04-20T13:07:50.756Z","avatar_url":"https://github.com/parsiya.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Random Code \u003c!-- omit in toc --\u003e\nThis repository contains most of the code that I write for my blog posts. I\nrealized I have random repositories on Github. I am consolidating them into one.\n\n# Individual Licenses \u003c!-- omit in toc --\u003e\nMost code in this repository is governed under the [MIT](LICENSE-code). Some\ncode may have a different license, check each directory for a license file.\n\n# Security Code \u003c!-- omit in toc --\u003e\nSecurity code will be mostly in\n[https://github.com/parsiya/Go-Security](https://github.com/parsiya/Go-Security).\n\n# Code Index \u003c!-- omit in toc --\u003e\nThis table will help but may not be current. Look inside each individual\ndirectory to see the code.\n\n- [WinAppDbg Tutorials](#winappdbg-tutorials)\n- [Proof of Concepts](#proof-of-concepts)\n    - [Code WSL Remote RCE - CVE-2021-43907](#code-wsl-remote-rce---cve-2021-43907)\n- [Semgrep](#semgrep)\n    - [Semgrep Autofix](#semgrep-autofix)\n- [Go](#go)\n    - [Cryptopals](#cryptopals)\n    - [Gophercises](#gophercises)\n    - [Blackfriday and gographviz](#blackfriday-and-gographviz)\n    - [Byte Wrangling and Windows Filetime](#byte-wrangling-and-windows-filetime)\n    - [filePath.Ext notes](#filepathext-notes)\n    - [SANS Holiday Hack Challenge 2018](#sans-holiday-hack-challenge-2018)\n- [Python](#python)\n    - [Hipchat Proxy](#hipchat-proxy)\n    - [Malware Adventure](#malware-adventure)\n    - [Customizing SimpleHTTPServer](#customizing-simplehttpserver)\n    - [pcap2csv](#pcap2csv)\n- [.NET Remoting](#net-remoting)\n- [Rust](#rust)\n    - [YAML Wrangling with Rust](#yaml-wrangling-with-rust)\n- [Burp](#burp)\n    - [Cryptography in Python Burp Extensions](#cryptography-in-python-burp-extensions)\n    - [Hiding OPTIONS in Burp](#hiding-options-in-burp)\n    - [Swing in Python Burp Extensions](#swing-in-python-burp-extensions)\n    - [Using Mozilla Rhino to Run JavaScript in Java](#using-mozilla-rhino-to-run-javascript-in-java)\n    - [Java SQLite Test](#java-sqlite-test)\n- [Cryptography](#cryptography)\n    - [Cryptopals in C](#cryptopals-in-c)\n    - [Decrypting an Application's Encrypted Log](#decrypting-an-applications-encrypted-log)\n- [Endpoint Discovery using Windows DNS Cache](#endpoint-discovery-using-windows-dns-cache)\n- [Octopress Image Popup Plugin Forked](#octopress-image-popup-plugin-forked)\n- [Calculator in C++](#calculator-in-c)\n\n## [WinAppDbg Tutorials](winappdbg)\nCode for my set of WinAppDbg tutorials.\n\n1. Copy the `winappdbg` directory to your Virtual Machine.\n2. Install Python, WinAppDbg and other software using instructions in part 1.\n3. Follow the tutorials and enjoy.\n4. If code is wrong, make an issue here or yell at me on Twitter/email/etc.\n\n- [Part 1 - Basics][winappdbg-1]\n- [Part 2 - Function Hooking and Others][winappdbg-2]\n- [Part 3 - Manipulating Function Calls][winappdbg-3]\n- [Part 4 - Bruteforcing FlareOn 2017 - Challenge 3][winappdbg-4]\n\n[winappdbg-1]: https://parsiya.net/blog/2017-11-09-winappdbg-part-1-basics/\n[winappdbg-2]: https://parsiya.net/blog/2017-11-11-winappdbg-part-2-function-hooking-and-others/\n[winappdbg-3]: https://parsiya.net/blog/2017-11-15-winappdbg-part-3-manipulating-function-calls/\n[winappdbg-4]: https://parsiya.net/blog/2017-11-15-winappdbg-part-4-bruteforcing-flareon-2017-challenge-3/\n\n## Proof of Concepts\n\n### [Code WSL Remote RCE - CVE-2021-43907](code-wsl-rce/README.md)\nSee the blog at\n[https://parsiya.net/blog/2021-vscode-wsl-rce/][code-wsl-blog].\n\nAlso exists in [https://github.com/parsiya/code-wsl-rce][code-wsl-gh].\n\n## Semgrep\n\n### [Semgrep Autofix](semgrep-autofix)\nPractice rules and code for the blog\n[A Hands-On Intro to Semgrep's Autofix][semgrep-autofix-blog].\n\n## Go\nGo is dope, also see https://github.com/parsiya/Go-Security.\n\n### [Cryptopals](cryptopals/go)\nDoing the Cryptopals challenges with `lol no generics`.\n\n### [Gophercises](gophercises/)\n[Gophercises](https://gophercises.com/) by Jon Calhoun.\n\n### [Blackfriday and gographviz](markdown-parsing)\nCode for blog post [Blackfriday's Parser and Generating graphs with gographviz][blackfriday-gographviz].\n\n### [Byte Wrangling and Windows Filetime](filetime-bytewrangling/)\nCode for blog post [Windows Filetime Timestamps and Byte Wrangling with Go][byte-wrangling].\n\n### [filePath.Ext notes](filepath-ext)\nCode for blog post [filepath.Ext Notes][filepath-ext].\n\n### [SANS Holiday Hack Challenge 2018](sans-holidayhack-2018)\nSee the write-up at:\n\n* https://parsiya.net/blog/2019-01-15-sans-holiday-hack-challenge-2018-solutions/\n\nFiles:\n\n* `decrypt.go`: Decrypts the password vault.\n* `cleaned-malware.ps1`: Cleaned version of the PowerShell malware.\n\n## Python\n\n### [Hipchat Proxy](hipchat-proxy)\nSmall proxy that I wrote for proxying Hipchat.\n\n- Main blog post\n    - [Proxying Hipchat Part 3: SSL Added and Removed Here][hipchat-3]\n- Related blogs:\n    - [Proxying Hipchat Part 1: Where did the Traffic Go?][hipchat-1]\n    - [Proxying Hipchat Part 2: So You Think You Can Use Burp?][hipchat-2]\n\n### [Malware Adventure](malware-adventure)\nSmall text adventure written in Python using PAWS (Python Adventure Writing\nSystem). Created as part of the class activity for \"Advanced Topics in Computer\nSecurity\" in 2013 at Johns Hopkins.\n\nPAWS 2.1 is a fork by `Matthias C. Hormann` at\n[https://github.com/Moonbase59/PAWS][paws-github]. PAWS was originally created\nby `Roger Plowman`.\n\n- Blog post\n    - [Malware Adventure][malware-adventure-blog]\n- Github repository (because there are links to it)\n    - [https://github.com/parsiya/malwareadventure][malware-adventure-github]\n\n### [Customizing SimpleHTTPServer](python-simplehttpserver)\nCode for the blog post\n[Customizing Python's SimpleHTTPServer][python-httpserver].\n\n### [pcap2csv](pcap2csv)\nA few python scripts to extract information from pcap files to csv.\n\n## [.NET Remoting](net-remoting)\nCode and example program used in:\n\n- [Intro to .NET Remoting for Hackers][net-remoting]\n\n## Rust\nFearless Concurrency.\n\n### [YAML Wrangling with Rust](yaml-wrangling-with-rust/)\nCode for the blog post [YAML Wrangling with Rust][yaml-rust].\n\n## Burp\nMostly Burp extension code.\n\n### [Cryptography in Python Burp Extensions](python-burp-crypto)\nCode and example program used in:\n\n- [Cryptography in Python Burp Extensions][python-burp-crypto-blog]\n\n### [Hiding OPTIONS in Burp](burp-filter-options)\nCode used in:\n\n- [Hiding OPTIONS - An Adventure in Dealing with Burp Proxy in an Extension][burp-filter-options-blog]\n\n### Swing in Python Burp Extensions\n\n* Part 1 blog: Swing in Python Burp Extensions - Part 1\n    * https://parsiya.net/blog/2019-11-04-swing-in-python-burp-extensions-part-1/\n    * [Part 1 code](jython-swing-1)\n* Part 2 blog:\n    * Swing in Python Burp Extensions - Part 2 - NetBeans and TableModels\n    * https://parsiya.net/blog/2019-11-11-swing-in-python-burp-extensions-part-2-netbeans-and-tablemodels/\n    * [Part 2 code](jython-swing-2)\n\n### [Using Mozilla Rhino to Run JavaScript in Java](java-rhino)\nCode used in:\n\n- [Using Mozilla Rhino to Run JavaScript in Java][java-rhino]\n\n### [Java SQLite Test](java-sqlite-test)\nSample code to learn how to interact with a SQLite database in Java with\n`org.xerial.sqlite-jdbc`.\n\n## Cryptography\n\n### [Cryptopals in C](cryptopals/c)\nDoing the first few cryptopals challenges in C (why?!).\n\n### [Decrypting an Application's Encrypted Log](decrypt-log)\nThis code decrypts an application's logs. It uses the Mersenne Twister Engine\nwith a specific seed to create a key stream. See the blog post at:\n\n* [The Encrypted Logz - Some Simple Reverse Engineering][encrypted-logz].\n\n## [Endpoint Discovery using Windows DNS Cache](dns-cache)\nA couple of PowerShell scripts that use the Windows DNS cache to discover application endpoints.\n\n- Blog post: [Thick Client Proxying - Part 9 - The Windows DNS Cache][dns-cache]\n\n## [Octopress Image Popup Plugin Forked](https://github.com/parsiya/octopress-image-popup-forked)\nThis is a fork of the Octopress Image Popup Plugin at\n[https://github.com/ctdk/octopress-image-popup][original-popup] by Jeremy\nBingham. The original instructions did not work for me out of the box so I made\nsome minor changes. Because it has a different license, I am keeping it in a\nseparate repository.\n\n- Blog post\n    - [Image Popup and Octopress][pop-up-blog].\n\n## [Calculator in C++](calculator.cpp)\nI found this code in an old archive. It's some calculator I wrote back in\nundergrad. It draws shapes on the screen and depending on where you click, you\nget a number. Pretty much all of it was done manually. The only thing I\nremember, is that I needed to have `C:\\\\egavga.bgi` for it to work. Fun times.\n\n\u003c!-- Links --\u003e\n\n[hipchat-1]: https://parsiya.net/blog/2015-10-08-proxying-hipchat-part-1-where-did-the-traffic-go/\n[hipchat-2]: https://parsiya.net/blog/2015-10-09-proxying-hipchat-part-2-so-you-think-you-can-use-burp/\n[hipchat-3]: https://parsiya.net/blog/2015-10-19-proxying-hipchat-part-3-ssl-added-and-removed-here/\n[net-remoting]: https://parsiya.net/blog/2015-11-14-intro-to-.net-remoting-for-hackers/\n[original-popup]: https://github.com/ctdk/octopress-image-popup\n[pop-up-blog]: https://parsiya.net/blog/2015-07-26-image-popup-and-octopress/\n[pop-up-github]: https://github.com/parsiya/octopress-image-popup-forked\n[paws-github]: https://github.com/Moonbase59/PAWS\n[malware-adventure-blog]: https://parsiya.net/blog/2014-09-21-malware-adventure/\n[malware-adventure-github]: https://github.com/parsiya/malwareadventure\n[code-wsl-blog]: https://parsiya.net/blog/2021-vscode-wsl-rce/\n[code-wsl-gh]: https://github.com/parsiya/code-wsl-rce\n[go-pcap]: https://parsiya.net/blog/2017-12-03-go-and-pcaps/\n[blackfriday-gographviz]: https://parsiya.net/blog/2018-10-28-blackfridays-parser-and-generating-graphs-with-gographviz/\n[byte-wrangling]: https://parsiya.net/blog/2018-11-01-windows-filetime-timestamps-and-byte-wrangling-with-go/\n[filepath-ext]: https://parsiya.net/blog/2018-11-10-filepath.ext-notes/\n[python-burp-crypto-blog]: https://parsiya.net/blog/2018-12-24-cryptography-in-python-burp-extensions/\n[burp-filter-options-blog]: https://parsiya.net/blog/2019-04-06-hiding-options-an-adventure-in-dealing-with-burp-proxy-in-an-extension/\n[dns-cache]: https://parsiya.net/blog/2019-04-28-thick-client-proxying-part-9-the-windows-dns-cache/\n[java-rhino]: https://parsiya.net/blog/2019-12-22-using-mozilla-rhino-to-run-javascript-in-java/\n[encrypted-logz]: https:///parsiya.net/blog/2020-04-17-the-encrypted-logz-some-simple-reverse-engineering/\n[python-httpserver]: https://parsiya.net/blog/2020-11-15-customizing-pythons-simplehttpserver/\n[semgrep-autofix-blog]: https://parsiya.net/blog/2021-10-25-a-hands-on-intro-to-semgreps-autofix/\n[yaml-rust]: https://parsiya.net/blog/2022-10-16-yaml-wrangling-with-rust/","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fparsiya%2Fparsia-code","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fparsiya%2Fparsia-code","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fparsiya%2Fparsia-code/lists"}