Uploaded December 2024 | Updated November 2026, 3 hours ago
I am given a large blob of junk text containing three potential "instructions". In part 1, I need to find all the mul(X,Y) instructions, multiple the values, and return the sum. In part 2, I'll process do() and don't() instructions that enable and disable the muls. I'll show a bad path I went down assuming alternating dos and don'ts, and solve with a loop over results from a regex match for all three instructions with a match statement.
2024 AOC repo: gitlab.com/0xdf/aoc2024
2024 AOC Intro vide: youtube.com/watch?v=4XKZZrhhiQE
VSCode Debug video: youtube.com/watch?v=cNhtk2Ob4B8
☕ Buy Me A Coffee: buymeacoffee.com/0xdf
[00:00] Introduction
[00:43] Part1 introduction
[01:09] Setup / data overview
[01:40] Getting instructions w/ regex
[03:20] Summing products
[04:25] Solving part 1
[04:39] Part 2 challenge
[05:50] Failed strategy with re.sub
[08:00] Refactor part 1 with loop
[11:00] Adding count for part2
[11:23] Conclusion
#adventofcode #python
I am given a large blob of junk text containing three potential "instructions". In part 1, I need to find all the mul(X,Y) instructions, multiple the values, and return the sum. In part 2, I'll process do() and don't() instructions that enable and disable the muls. I'll show a bad path I went down assuming alternating dos and don'ts, and solve with a loop over results from a regex match for all three instructions with a match statement.
2024 AOC repo: gitlab.com/0xdf/aoc2024
2024 AOC Intro vide: youtube.com/watch?v=4XKZZrhhiQE
VSCode Debug video: youtube.com/watch?v=cNhtk2Ob4B8
☕ Buy Me A Coffee: buymeacoffee.com/0xdf
[00:00] Introduction
[00:43] Part1 introduction
[01:09] Setup / data overview
[01:40] Getting instructions w/ regex
[03:20] Summing products
[04:25] Solving part 1
[04:39] Part 2 challenge
[05:50] Failed strategy with re.sub
[08:00] Refactor part 1 with loop
[11:00] Adding count for part2
[11:23] Conclusion
#adventofcode #python
![Uncheesable [0xff: One Last Address]
The HTB Content team made me a goodbye CTF consisting of four challenges. In this video, Ill solve Uncheesable, a forensics challenge involving a memory dump from a custom Linux kernel. Ill pull the necessary kernel information from the dump to build the symbols information necessary for Volatility to interact with the dump. Then Ill find a malicious process that reads an ELF from a socket and writes it to a temporary file in memory. Ill find that file in memory and dump it to get the flag.
Boot headers: https://docs.kernel.org/arch/x86/boot.html
vmlinux-to-elf: https://github.com/marin-m/vmlinux-to-elf
btf2json: https://github.com/vobst/btf2json
uv CheatSheet: https://0xdf.gitlab.io/cheatsheets/uv
Linux syscalls: https://www.chromium.org/chromium-os/developer-library/reference/linux-constants/syscalls/#x86_64_319
memfd_create man page: https://man7.org/linux/man-pages/man2/memfd_create.2.html
Fakedoor writeup: https://blog.alpha-carinae.xyz/posts/fakedoor-vol3/#constructing-objects
☕ Buy Me A Coffee: https://www.buymeacoffee.com/0xdf
[00:00] Introduction
[01:15] Challenge introduction
[01:49] HTB blog post overview
[03:52] Carving the bzImage file
[10:08] Kernel banners w/ volatility
[11:19] Creating System.map file
[12:38] Creating ELF from kernel
[13:20] Generating symbols
[15:26] Volatility3 works! Process list!
[16:24] Using plugins to get suspicious file
[21:27] Ghidra RE
[26:36] Recovering the in-memory file
[33:52] Conclusion
#ctf #volatility #vol3 #custom-linux-kernel #ghidra #forensics Uncheesable [0xff: One Last Address]](https://i.ytimg.com/vi/txL58cgIYkw/mqdefault.jpg)
![Hacking PyJWT for Algorithm Confusion Attack [HackTheBox CyberMonday]
In the CyberMonday box from HackTheBox, the foothold involves exploiting an algorithm confusion attack against a JWT. When I went to sign the new JWT with the public key, PyJWT rejected me. In this video, well show the rejection, find the code responsible, and modify it to allow me to sign.
HackTheBox CyberMonday: https://www.hackthebox.com/machines/cybermonday
CyberMonday Blog Post: https://0xdf.gitlab.io/2023/12/02/htb-cybermonday.html
☕ Buy Me A Coffee: https://www.buymeacoffee.com/0xdf
[00:00] Introduction
[02:16] Review public key
[02:38] Creating Virtual Environment
[04:17] Failure in Python Terminal
[08:10] Finding Responsible Code
[10:08] Modifying to Allow
[11:25] Conclusion
#pentest #ctf #bugbounty #python #pyjwt Hacking PyJWT for Algorithm Confusion Attack [HackTheBox CyberMonday]](https://i.ytimg.com/vi/uzHXHaRFckE/mqdefault.jpg)
![Day 10: Pipe Maze [AOC2023 Python]
For Advent of Code 2023 Day 10, I get a map of pipes that includes a loop and a bunch of random pipes not a part of the loop. In part 1, Ill use a breadth first search to find all the pipes in the loop. In part 2, Ill use ray casting to find which spots are enclosed in the loop.
Code 2023 AOC: https://gitlab.com/0xdf/aoc2023
Challenge Link: https://adventofcode.com/2023/day/10
Ray casting algorithm: https://en.wikipedia.org/wiki/Point_in_polygon
☕ Buy Me A Coffee: https://www.buymeacoffee.com/0xdf
[00:00] Part 1 description
[01:29] Input analysis
[02:08] Find start
[03:40] Find start type
[08:40] Update grid
[09:18] BFS
[11:30] get_valid_moves
[12:59] Debugging small issues
[14:20] Solve part 1
[14:35] Part 2 description
[16:19] Ray casting algorithm
[17:07] Removing non-loop items
[18:38] Walk each line
[22:30] Test cases
[23:24] Solve part 2
[23:32] Summary
#adventofcode #python Day 10: Pipe Maze [AOC2023 Python]](https://i.ytimg.com/vi/vJSETN-aTvw/mqdefault.jpg)
![Jumpio Adventure [HTB Stack Smash CTF]
As a teaser for the upcoming Stack Smash CTF, HackTheBox released Jumpio Adventure. Its a simple integer underflow followed by a buffer overflow to run the win function. Well show playing the game, reversing with Ghidra, debugging with gdb / Peda, and writing an exploit with Python and pwntools.
Stack Smash CTF: https://ctf.hackthebox.com/event/details/stacksmash-ctf-2538
Teaser Event: https://ctf.hackthebox.com/event/details/stacksmash-ctf-playground-2542
Peda: https://github.com/longld/peda
uv CheatSheet: https://0xdf.gitlab.io/cheatsheets/uv
☕ Buy Me A Coffee: https://www.buymeacoffee.com/0xdf
[00:00] Introduction
[00:48] Challenge introduction
[02:02] Playing game
[04:25] Ghidra RE
[14:00] BOF POC
[15:55] Finding overflow offset
[17:22] Solve script
[21:40] Using pwntools ELF
[22:56] Remote exploit
[23:53] Conclusion
#bugbounty #ctf #pwn #ghidra #reverse-engineering Jumpio Adventure [HTB Stack Smash CTF]](https://i.ytimg.com/vi/vQW113BLfvQ/mqdefault.jpg)
![Reversal [HackTheBox - Coding Challenge]
Reversal is a very easy challenge. I read in a string and return it reversed. Ill solve it quickly with slices, and then go into a rabbit hole showing reversed, and how it returns a generator.
☕ Buy Me A Coffee: https://www.buymeacoffee.com/0xdf
[00:00] Introduction
[00:30] Exploring input
[01:15] strings slices
[02:50] Solving with reversed
[03:55] Generators vs lists
[05:55] Exhausted generators
#python Reversal [HackTheBox - Coding Challenge]](https://i.ytimg.com/vi/vacwbdpXogw/mqdefault.jpg)
![(More) AWS CLI [Sans Holiday Hack 2022 - Cloud Ring]
A second challenge looking at the AWS CLI, this time using Trufflehog to leak creds from a public repo, and then using those to enumeration my access, eventually getting access to a S3 bucket and lambda functions, discovering a private URL.
SANS Holiday Hack 2022 writeup: https://0xdf.gitlab.io/holidayhack2022/cloud
☕ Buy Me A Coffee: https://www.buymeacoffee.com/0xdf
#HolidayHack
[00:00] Introduction
[01:02] Trufflehog to get secrets
[02:13] Configure aws with secrets
[03:03] List managed policies for current user
[05:47] Getting policy details
[06:30] Getting default version of the policy
[07:46] List inline policies for current user
[08:56] Get policy associated with current user
[10:19] List objects in S3 bucket
[11:28] List lambda functions
[12:36] Find URL of function
[14:10] Trying to visit URL - error
[14:26] Wrap-up (More) AWS CLI [Sans Holiday Hack 2022 - Cloud Ring]](https://i.ytimg.com/vi/vvsAgpurH-Q/mqdefault.jpg)
![Playground [AOC2025 Day 8]
Advent of Code 2025 Day 8 involves connecting points in order of their distances apart. In part 1, Ill connect the closest 1000 points, and find the size of the three largest resulting sets. In part 2, Ill run until all the points are in one large set, calculating the answer from the x coordinates of the last two joined boxes. Ill use Union Find to manage my sets. Claude solves it almost the exact same way, other than that it uses a seperate loop for each part, whereas I did it in one loop.
Union Find Writeup: https://cp-algorithms.com/data_structures/disjoint_set_union.html
Union Find Video: https://www.youtube.com/watch?v=ayW5B2W9hfo
Solutions Repo: https://gitlab.com/0xdf/aoc2025
VSCode Debug Setup: https://www.youtube.com/watch?v=cNhtk2Ob4B8
Claude: https://claude.ai/
☕ Buy Me A Coffee: https://www.buymeacoffee.com/0xdf
[00:00] Introduction
[01:18] Pulling / examining input
[01:55] Processing points
[03:02] Calculating distances
[05:52] Union Find overview
[07:51] Create parent structure
[09:21] find_set function
[10:36] merge_sets function
[11:16] Merge closest sets
[12:50] Calculating set sizes
[14:10] Calculating part1 solution
[16:10] Solving part 1
[16:46] Part 2 introduction
[17:05] Strategy
[17:43] Refactoring dists loop
[18:45] Counting merges
[20:14] Finishing refactor of part 1
[20:48] Solving part 2
[21:05] Recapping solution
[21:29] Solving with Claude
[22:50] Analysis of Claudes solution
[26:29] Conclusion
#AdventOfCode #claude Playground [AOC2025 Day 8]](https://i.ytimg.com/vi/w9lRDqtWEA4/mqdefault.jpg)
![Copy Fail Explained [CVE-2026-31431]
Copy Fail is the latest Linux privesc CVE, and its a relatively simply exploit that overwrites files in the in-memory cache. The exploit will abuse this by overwriting the cahce for a SetUID binary and then running it. In this video Ill walk though the authors POC, show my own deobfuscated POC, and show how the vulnerability works. To close, Ill run it on the HTB Snapped machine and show how to cleanup the exploit.
Copy-Fail: https://copy.fail/#exploit
Original POC: https://github.com/theori-io/copy-fail-CVE-2026-31431
Deobfuscated POC: https://github.com/0xdf223/copy-fail-CVE-2026-31431
HTB Snapped post: https://0xdf.gitlab.io/2026/04/01/htb-snapped.html
☕ Buy Me A Coffee: https://www.buymeacoffee.com/0xdf
[00:00] Introduction
[01:13] Authors writeup
[02:00] Authors POC
[04:25] Deobfuscated POC
[04:26] Three interesting cases: shadow, root.txt, .bash_history
[05:17] Vulnerability / exploit overview
[06:56] Walking through POC
[08:52] Analysis of the compressed hex payload
[13:04] Running on HTB Snapped
[13:55] Cleanup
[14:55] Conclusion
#copy-fail #privescc #cybersecurity Copy Fail Explained [CVE-2026-31431]](https://i.ytimg.com/vi/wQ914geKOcw/mqdefault.jpg)
![LAN Party [Day 23 - Advent of Code 2024 - Python]
Im given a list of connections each showing two connected computers. Ill first need to identify triplets, three computers where each is connected to the other two. In part two, Ill use recusion to find the largest fully connected group.
2024 AOC repo: https://gitlab.com/0xdf/aoc2024/
2024 AOC Intro video: https://www.youtube.com/watch?v=4XKZZrhhiQE
VSCode Debug video: https://www.youtube.com/watch?v=cNhtk2Ob4B8
☕ Buy Me A Coffee: https://www.buymeacoffee.com/0xdf
[00:00] Part1 introduction
[01:28] Input review
[02:00] Parsing input into pairs
[02:34] Creating dict of connections
[03:18] Looping over nodes to find triples
[05:30] Filtering for starts with t
[06:10] Solving part 1
[06:21] Part 2 challenge
[06:53] Recursive function to find groups
[10:12] Checking all nodes
[10:50] Solving part 2
[11:13] Conclusion
#adventofcode #python LAN Party [Day 23 - Advent of Code 2024 - Python]](https://i.ytimg.com/vi/x-CMuXDvMVY/mqdefault.jpg)
![Day 21: Step Counter [AOC2023 Python]
For Advent of Code 2023 Day 21, Im given a grid of spaces and rocks, and asked to find how many spaces an elf could stop in after exactly 64 steps. Ill solve this with a queue and a breadth first fill. In part two, the number of steps changes to 26,501,365, which means I cant walk it anymore, but rather have to think about the diffent kinds of grids that might be encountered, how many possible stopping points there are, and how many of each type.
Code 2023 AOC: https://gitlab.com/0xdf/aoc2023
Challenge Link: https://adventofcode.com/2023/day/121
☕ Buy Me A Coffee: https://www.buymeacoffee.com/0xdf
[00:00] Part 1 description
[01:15] genday / input analysis
[02:04] Format grid, find start
[03:58] All steps via queue
[09:12] Debugging, fix mistake
[09:50] Solve part 1
[10:11] Part 2 description
[11:06] Refactor part 1 into function
[12:35] Input analysis again
[14:20] Complete grid analysis
[16:43] Introducing toy example
[19:06] Counting corners
[21:34] Counting interior
[24:16] Outer edges
[28:54] Inner edges
[30:38] Solve part 2
[30:42] Summary
#adventofcode #python Day 21: Step Counter [AOC2023 Python]](https://i.ytimg.com/vi/xD0g4BtUnP0/mqdefault.jpg)
![Exploring Docker Registry Auth [HackTheBox RegistryTwo]
Im looking at a docker registry server and an auth server. Ill show how I can manually request a token from the auth server, and then use Wireshark and Burp to look at how docker does that for me when running docker pull.
HackTheBox RegistryTwo: https://www.hackthebox.com/machines/registrytwo
RegistryTwo Blog Post: https://0xdf.gitlab.io/2024/02/03/htb-registrytwo.html#docker-registry tcp-5000 5001
DockerRegistryGrabber: https://github.com/Syzik/DockerRegistryGrabber
Foxyproxy / Burp Video: https://www.youtube.com/watch?v=iTm33Miymdg
☕ Buy Me A Coffee: https://www.buymeacoffee.com/0xdf
[00:00] Introduction
[01:05] Web browser registry interactions
[03:42] curl manual registry pulls
[06:26] Bit about TLS certificates
[06:51] Using docker to pull
[07:43] Wireshark analysis
[09:05] Creating Burp proxies
[11:04] Request analysis in Burp
[12:16] Modifying 401 experiment
[14:22] Conclusion
#pentest #ctf #bugbounty #docker #docker-registry Exploring Docker Registry Auth [HackTheBox RegistryTwo]](https://i.ytimg.com/vi/xqYQ76u8bM0/mqdefault.jpg)