Descent into Wireland: Busting CypherCon 5's Badge Cryptography (how I got banned from OpenAI ChatGPT)
Dustin Heywood
Overview
Dustin Heywood, known as Evil Mog, an Executive Managing Hacker at IBM X-Force and a prominent member of Team Hashcat, presented a captivating talk at CypherCon. Originally slated to discuss hashcat techniques, Heywood instead plunged into a fascinating, and at times infuriating, journey of reverse-engineering the intricate and custom cryptography of the CypherCon 5 conference badges. This talk, titled "Descent into Wireland," details his relentless pursuit to crack a seemingly impossible challenge, revealing critical flaws in custom cryptographic implementations and the perils of predictable random number generation.

Key moments
- 2:00 Welcome to Mogland: Banned from OpenAI intro
- 7:30 CypherCon 5 badges used custom 80-bit Spec cipher
- 14:30 Exploiting Perl's insecure random number generator for keys
- 15:00 Why OpenAI banned speaker for 80-bit cipher research
- 19:00 Live demo: cracking the 80-bit Spec cipher key
- 24:50 How speaker killed Defcoin cryptocurrency with GPU mining
- 33:30 Bribing the Taliban to acquire the evil.af domain
- 38:00 WPA2 Enterprise vulnerability: NTLMv1 under the hood
Descent into Wireland: Busting CypherCon 5's Badge Cryptography (how I got banned from OpenAI ChatGPT)
Speakers: Dustin Heywood, Executive Managing Hacker at IBM X-Force
Conference: CypherCon
YouTube: https://www.youtube.com/watch?v=FVF6SvnqqdI
Overview
Dustin Heywood, known as Evil Mog, an Executive Managing Hacker at IBM X-Force and a prominent member of Team Hashcat, presented a captivating talk at CypherCon. Originally slated to discuss hashcat techniques, Heywood instead plunged into a fascinating, and at times infuriating, journey of reverse-engineering the intricate and custom cryptography of the CypherCon 5 conference badges. This talk, titled "Descent into Wireland," details his relentless pursuit to crack a seemingly impossible challenge, revealing critical flaws in custom cryptographic implementations and the perils of predictable random number generation.
Heywood’s odyssey began with a personal vendetta against an "impossible" black badge, leading him down an "ADHD rabbit hole" that culminated in a unique blend of technical deep dive, humorous anecdotes, and a surprising run-in with OpenAI, which temporarily banned his account for developing a tool to crack the badge's 80-bit cipher. The talk serves as a compelling case study on the dangers of "rolling your own crypto," even in a gamified context, and offers invaluable lessons for developers, security professionals, and anyone interested in the often-unforeseen complexities of seemingly simple systems.
Background
▶ Watch: Welcome to Mogland: Banned from OpenAI intro (2:00)
The CypherCon 5 badges, affectionately dubbed "flamingos," were far more than mere conference identifiers; they were the core of an elaborate, gamified ecosystem. These badges communicated over infrared (IR), functioning as a digital Tamagotchi-esque experience with a bizarre twist. Participants could earn "credits" by interacting with other badges, but the system also incorporated elements like "sickness," "death," "pregnancy" (for speaker/parrot badges to "lay eggs" in vending machines), and even "pink eye" – a badge-borne STD that spread between devices and increased food consumption. The game featured various interactive "badges" beyond the wearables, including "outhouses" for "poo" disposal and "vending machines" that dispensed electronic badges, including the elusive black badge.
The central challenge and the source of Heywood's obsession was the encryption protecting critical badge transactions. The "toy makers" behind the badges had implemented a custom version of the Speck cipher, but with a crucial modification: they reduced its typical 128-bit rounds down to a non-standard 80 bits. Compounding this "roll your own crypto" approach, the keys for this custom cipher were generated using Perl's rand() function without proper seeding via srand(). This fundamental design flaw meant that the keys, rather than being truly random, were entirely predictable – a vulnerability that no one had cracked during the conference, making the black badge challenge seemingly insurmountable. Heywood’s frustration with this "impossible" challenge, and the fact that he was the only one to effectively beat the system, spurred his deep dive, transforming a planned talk on hashcat into this exposé.
Key Findings
▶ Watch: Exploiting Perl's insecure random number generator for keys (14:30)
Heywood's investigation yielded several critical findings, demonstrating how a combination of social engineering, protocol analysis, and cryptographic weakness exploitation led to the complete compromise of the CypherCon 5 badge system.
Initially, without even touching the encryption, Heywood's team achieved significant success by jackpotting the vending machine. This was accomplished by reverse-engineering the social ping mechanism. By understanding the packet header (smh?), the type 00 for social pings, and the big-endian badge ID, they could craft valid, unencrypted ping packets. Crucially, they also deciphered the two's complement checksum (summing header and badge bytes, adding one, and checking for modulo 256 to zero). This allowed them to fake interactions, rapidly accumulate credits, and obtain stacks of badges from the vending machine.
Despite this early victory, the core cryptographic challenge remained. Even after bribing a "wire engineer" for full disclosure of the vendor dump format – which detailed badge status like sickness, credits spent, and "seen IDs" (a single bit for each interaction, limiting total credits) – the encryption for "spend credit" and "confirmed credit spend" packets proved resistant. The badge's maximum honest credits (768) were far less than the cost of a black badge (65536), highlighting a fundamental design flaw that necessitated an exploit. A temporary patch by Wire, the badge creator, on day two, allowed the vending machine to bypass initial credit checks, simplifying the jackpot process but not addressing the underlying crypto.
The breakthrough came with the realization that the 10-byte Speck keys for type three and type four credit transactions were generated using Perl's rand() function without any preceding srand() call. This meant the keys were derived from a predictable CD rand sequence. Heywood developed a hacky Python script to perform seed farming, iterating through potential seeds to generate 10-byte random sequences and comparing them against published keys (which were released after the conference). This revealed that keys were generated in batches, allowing him to expand his tool to generate 200 keys per seed and find matches.
Ultimately, Heywood developed a Go tool that, given type two and type three packets, could generate and test potential Speck keys based on the predictable rand() sequence. This tool was the direct cause of his temporary deactivation from OpenAI, which flagged it as a "hacking" tool, despite the 80-bit Speck cipher with predictable keys being a trivial security risk for anything beyond a conference badge. This incident underscored a broader issue of how AI platforms interpret security research tools.
Technical Deep Dive
▶ Watch: Live demo: cracking the 80-bit Spec cipher key (19:00)
The CypherCon 5 badge system relied on a custom infrared (IR) protocol operating at 3000 baud serial, modulated over IR. While a Flipper Zero could capture and relay these IR signals, it lacked the capability to decode them. The "hack board" sold in the vending machine was necessary for full interaction and decoding, including forcing more credits.
The protocol defined various packet types:
00: The standard ping payload for badge-to-badge communication, awarding one credit.- Request for a dump: A simple request with no payload.
- Badge dump: A comprehensive data dump from a badge, useful for debugging.
- Spend Credit and Confirmed Credit Spend: These were the critical transaction types, encrypted by the custom 80-bit Speck cipher. This encryption was the primary target of Heywood's efforts.
- Other types: Included
Hyron(revive),set quest,request food,confirm food,clear egg(ending pregnancy),Uber mode(special powers),complete quest, and areset badgefunction.
The initial attack to jackpot the vending machine exploited the unencrypted 00 social ping packets. The structure was as follows:
- Header: Offsets 0 to 5 contained the fixed string
smh?. - Type: Offset 6 held
00for a standard social ping. - Badge ID: Offsets 7 to 9 contained the badge's unique ID in big-endian format (e.g.,
00031F). - Checksum: A standard two's complement checksum was used. It was calculated by summing the header bytes and badge ID bytes, adding one, and then performing a modulo 256 operation. If the result was zero, the checksum was valid. This was easily replicated in Python, allowing Heywood to forge ping packets without needing to decrypt anything.
The vendor dump provided extensive, albeit unencrypted, information about a badge's state. This included flags for sick, con started, pink eye, quest started, credits spent (e.g., 7 credits), slept for a number of hours, hyper, pregnant for a certain number of seconds, pooped, and knocked up x number of times. A particularly interesting field was seen IDs, which represented every badge interacted with as a single bit. This design limited the maximum honest credits to 768, far below the 65536 credits required for a black badge, highlighting the intended impossibility of the challenge without exploiting the system.
The core cryptographic weakness lay in the key generation for the type three and type four credit transactions. The keys, a 10-byte SPEC key, were derived using Perl's rand() function. Crucially, the speaker discovered that the developer failed to use srand() to seed the random number generator. This meant the rand() function produced a completely predictable sequence, effectively making it a CD rand (counter-driven random) system. This predictability was the Achilles' heel of the custom crypto.
Heywood's method to exploit this was seed farming. He wrote a Python script to iterate through all possible rand() seeds. For each seed, it would generate a 10-byte sequence and compare it against the previously published keys (released by the badge creator after the conference). This process yielded 10 initial hits, indicating that badges were likely generated in batches. He then expanded his tool to generate 200 keys per seed, further refining the attack.
The final step was the development of a Go tool. This tool took type two (vendor dump) and type three (credit request) packets, along with a dump one hex (a unique, single-use badge value), the badge ID, and the number of credits requested. It then leveraged the understanding of the predictable rand() sequence to generate potential keys, run the 80-bit Speck cipher with those keys, and test for valid decryption. The live demo showed the tool taking approximately two minutes to successfully crack the SPEC key, allowing the forging of transactions and complete control over badge mechanics.
As a side note, Heywood also mentioned discovering a firmware bug: by sending a type five command, which was not correctly implemented, other badges could be crashed. This highlights the general lack of robust error handling and input validation in the badge's firmware.
Demo / Proof of Concept
▶ Watch: How speaker killed Defcoin cryptocurrency with GPU mining (24:50)
During the presentation, Evil Mog performed a live demonstration of his custom Go tool, which was central to cracking the CypherCon 5 badge cryptography. The demo, though briefly interrupted by presentation software issues, clearly illustrated the process and effectiveness of his exploit.
The tool’s functionality revolved around leveraging the identified weakness in the key generation. The inputs required for the Go tool were:
type four hex: The hexadecimal representation of atype fourpacket (confirmed credit spend).type three hex: The hexadecimal representation of atype threepacket (credit request).dump one hex: A unique, single-use value generated by the badge, often found in the vendor dump. This value was crucial as the badge firmware would ignore communications if it saw this specific value in the string again, a peculiar "wire stuff" design.badge ID: The identifier of the target badge.number of credits requested: The amount of credits involved in the transaction.
Upon execution, the Go tool would systematically generate potential Speck keys by simulating the predictable Pearl rand() sequence. It then used these generated keys to attempt decryption of the type three and type four packets. The process, as demonstrated live, took approximately two minutes to complete. The output of the tool was the successfully cracked SPEC key.
With this key, Heywood explained, an attacker could then forge transactions at will, effectively manipulating any aspect of the badge game. This included granting unlimited credits, curing "pink eye," or making badges pregnant, thereby gaining complete control over the badge ecosystem. The demo served as a powerful proof of concept, validating his reverse-engineering efforts and the critical vulnerability introduced by the flawed random number generation.
Beyond the crypto crack, Heywood also alluded to another vulnerability he discovered in the badge firmware. By sending a specific type five command, which was "not implemented correctly," it was possible to crash other badges. He stated he had a version of the exploit that could crash "any badge it looks at," though he assured the audience he would not use it maliciously. This secondary finding further underscores the overall lack of robust security practices in the badge's development.
Defensive Implications
▶ Watch: WPA2 Enterprise vulnerability: NTLMv1 under the hood (38:00)
The "Descent into Wireland" talk, while focused on a conference badge game, offers several critical defensive implications applicable to any system involving custom hardware, communication protocols, and cryptography.
- Avoid Custom Cryptography ("Roll Your Own Crypto"): The most glaring lesson is the inherent danger of implementing custom cryptographic solutions. The CypherCon 5 badges used a modified Speck cipher (80-bit instead of 128-bit rounds). Even with a known, standardized cipher as a base, modifications introduce unknown weaknesses and eliminate the benefits of peer review and widespread cryptanalysis. Defenders should always advocate for established, well-vetted, and standardized cryptographic algorithms and protocols.
- Robust Random Number Generation (RNG) is Paramount: The core vulnerability exploited was the use of Perl's
rand()withoutsrand(), leading to a predictable PRNG (CD rand). This allowed for key prediction and decryption. Any system relying on cryptography, especially for key generation, must use cryptographically secure random number generators (CSRNGs) and ensure they are properly seeded with sufficient entropy. Predictable RNGs are a fundamental cryptographic flaw that can render an entire system insecure.
- Secure Protocol Design and Implementation: Even simple IR protocols need careful design. The ability to easily reverse-engineer packet structures, checksums, and badge IDs (as seen with the initial social ping exploit) highlights the need for authentication and integrity checks at every layer, not just at the encryption layer. Data validation on inputs (e.g., the
type fivecommand crashing badges) is crucial to prevent denial-of-service or arbitrary code execution.
- Comprehensive Firmware Security: The existence of bugs like the
type fivecrash demonstrates a lack of thorough firmware testing and secure coding practices. All firmware, regardless of its perceived low-security context (like a conference badge), should undergo rigorous security audits, fuzzing, and penetration testing to identify and remediate vulnerabilities before deployment.
- The Perils of "Security by Obscurity": The badge creators likely believed their custom 80-bit Speck cipher was secure because it was unknown and unpublished. This reliance on obscurity proved futile against a determined attacker. True security comes from robust, well-understood algorithms and implementations, not from hiding their details.
- AI Tooling and Security Research: The incident with OpenAI banning Heywood's account raises questions about how AI platforms classify and respond to security research tools. Defenders and security researchers should be aware that their tools, even if designed for educational or defensive purposes, might be misinterpreted by automated systems. This highlights a need for better communication and possibly more nuanced classification models within AI platforms to distinguish legitimate security research from malicious activity.
- Patching Addresses Symptoms, Not Root Causes: While the badge creator issued a patch to the vending machine to bypass initial credit checks, this only addressed a symptom of the game's imbalance, not the underlying cryptographic vulnerability. Defenders must strive to identify and fix root causes rather than applying superficial patches that can give a false sense of security.
Key Takeaways
- Custom Cryptography is a Security Risk: "Rolling your own crypto," even by modifying standard ciphers, almost inevitably introduces vulnerabilities and should be avoided in favor of well-vetted, standardized algorithms.
- Random Number Generation is Critical: The use of predictable random number generators (like Perl's
rand()withoutsrand()) is a severe cryptographic flaw that can lead to complete system compromise, as demonstrated by the predictable 80-bit Speck keys. - Persistence and Reverse Engineering Pay Off: Seemingly "impossible" challenges can be overcome through meticulous reverse engineering of protocols, firmware, and underlying logic, even when initial cryptographic analysis fails.
- Game Systems Reflect Real-World Flaws: Security vulnerabilities found in gamified systems, such as conference badges, often mirror fundamental flaws present in more critical real-world applications and infrastructure.
- AI Platforms Can Misinterpret Security Tools: Developing tools for legitimate security research, even for low-stakes targets like a conference badge, can lead to unexpected consequences like temporary bans from AI services due to misclassification.
- Conference Badge Challenges are Not for the Faint of Heart: As humorously noted by the speaker, engaging in deep-dive conference badge challenges can be an all-consuming, sanity-testing endeavor, often requiring immense dedication.
About the Speaker(s)
Dustin Heywood, professionally known as Evil Mog, is an Executive Managing Hacker at IBM X-Force. He is a highly respected figure in the cybersecurity community, particularly renowned for his expertise in password cracking as a prominent member of Team Hashcat. Heywood’s background includes experience as a former network engineer, providing him with a deep understanding of infrastructure. He is a prolific collector of black badges, boasting seven or more, signifying his consistent success in conference hacking challenges.
Beyond his professional role, Heywood identifies as the "Bishop of the Church of Wi-Fi" and is known for his candid and often humorous approach to security. His extensive experience includes involvement in significant vulnerabilities like DROWN (Deciphering RSA with Obsolete and Weakened eNcryption) and, famously, "killing Defcoin," Defcon's ill-fated cryptocurrency. Outside of hacking, he enjoys a diverse range of hobbies, including scuba diving, motorcycles (owning a chipped ZX4R), and working as a special effects pyrotechnician. He is also a self-proclaimed "saki snob" and a food judge for Canada's 100 best restaurants. Dustin Heywood is an active presence on Twitter (evil_mog) and Discord, where he continues to share his knowledge and insights.
Reviews
Dr. Zero (Offensive Security Researcher) — STRONG ACCEPT
Heywood spent a weekend going completely feral over a conference badge's custom 80-bit SPEC implementation. It's a classic case study in why you don't roll your own crypto and why relying on unseeded Pearl rand() is a death sentence for your key generation.
Heather Calloway (CISO) — SOLID
This is an entertaining autopsy of a conference badge's custom cryptography, but its business relevance is strictly as a cautionary tale for embedded systems. If your organization manufactures IoT devices or relies on bespoke hardware, this underscores exactly why we forbid developers from rolling their own crypto. Otherwise, it's a fun hardware hacking write-up rather than required viewing for leadership.