Of Microchips and Mammals

Elliott Nash (IT Help Desk Analyst)

Security BSides London 2023 · Day 1 · Rookie Track

Overview

In his engaging BSides London talk, "Of Microchips and Mammals," Elliott Nash, an IT Help Desk Analyst, delves into the often-overlooked technical intricacies of pet microchips. Leveraging the popular Flipper Zero multi-tool, Nash embarks on a personal journey to reverse engineer the encoding mechanism of FDx-B animal microchips. The presentation highlights a critical gap in public understanding and existing documentation regarding how these ubiquitous identification devices store and transmit data, particularly the animal's unique ID and associated metadata.

Watch on YouTube

Visual summary for Of Microchips and Mammals by Elliott Nash
Visual summary for Of Microchips and Mammals by Elliott Nash

Key moments

  1. 0:00 Introduction and Flipper Zero's animal microchip feature
  2. 1:30 Initial microchip data and decoding challenge
  3. 3:40 Decoding the ID: hex vs. binary pitfall
  4. 5:30 Binary sections spanning hex characters
  5. 6:20 Recap: How to decode pet microchip information
  6. 8:10 Critical security finding: the redaction fail
  7. 10:00 Unsolved microchip data challenges for audience
  8. 11:40 Q&A: ISO standard and other RFID tools

Of Microchips and Mammals

Speakers: Elliott Nash, IT Help Desk Analyst

Conference: BSides London

YouTube: https://www.youtube.com/watch?v=CNASXKf6q6g

Overview

In his engaging BSides London talk, "Of Microchips and Mammals," Elliott Nash, an IT Help Desk Analyst, delves into the often-overlooked technical intricacies of pet microchips. Leveraging the popular Flipper Zero multi-tool, Nash embarks on a personal journey to reverse engineer the encoding mechanism of FDx-B animal microchips. The presentation highlights a critical gap in public understanding and existing documentation regarding how these ubiquitous identification devices store and transmit data, particularly the animal's unique ID and associated metadata.

Nash's talk is more than just a technical exposition; it's a compelling narrative of discovery driven by curiosity and a love for animals. He systematically dissects the FDx-B protocol's data structure, revealing how seemingly simple hexadecimal strings translate into meaningful identification numbers. The significance of this research extends beyond mere technical curiosity, exposing a widespread misunderstanding of data representation that leads to ineffective privacy redaction and potential data exposure for millions of pet owners. By meticulously detailing his process, Nash underscores the importance of a deep, bit-level understanding of protocols for robust security and privacy practices.

Background

▶ Watch: Introduction and Flipper Zero's animal microchip feature (0:00)

The genesis of this research stems from the speaker's fascination with the Flipper Zero, a versatile pocket-sized multi-tool designed for pentesters and hardware hackers. Among its numerous capabilities – including sub-GHz radio, infrared, and Bluetooth – the RFID reader/writer/emulator feature particularly caught Nash's eye. Within the Flipper Zero's RFID menu, he discovered the "ASK and animal bit" option, immediately connecting it to pet microchips. Driven by a passion for animals and a hacker's curiosity, Nash's first experiment involved scanning his own dog's microchip.

The initial scan yielded a promising result: a read of his pet's microchip, displaying the protocol as FDx-B, a string of hexadecimal characters (the "data"), an "ID," and a "prefix," along with confirmation that the subject was an "animal" and a section labeled "bits," which were all zeros. The challenge arose when Nash attempted to back up this data. Copying the file to his computer and opening it with cat revealed only the raw hexadecimal data, not the human-readable ID or prefix. This discrepancy sparked his investigation: how was the raw hexadecimal data converted into the useful "information" that a vet would use?

Initial research proved challenging. While the Flipper Zero's firmware is open source, Nash found the C code difficult to parse. Public documentation for FDx-B existed, but it didn't seem to correlate directly with the data he was observing, often indicating more data should be present than he could discern. Faced with these dead ends, Nash resolved to reverse engineer the encoding himself, adopting a slower but ultimately more insightful, hands-on approach.

Key Findings

▶ Watch: Decoding the ID: hex vs. binary pitfall (3:40)

Elliott Nash's meticulous reverse engineering process yielded several crucial findings regarding the encoding of pet microchip data using the FDx-B protocol:

  1. ID Encoding: The primary identification number for the animal is stored within the first 38 bits of the raw binary data. Crucially, this data is read Most Significant Bit (MSB) first, or from left to right, which often contradicts the default behavior of many binary-to-decimal calculators.
  1. Country/Manufacturer Code Encoding: The segment Nash initially referred to as a "prefix" is, in fact, a country code or manufacturer code, depending on regional laws and specific manufacturers. This code is encoded in the subsequent 10 bits immediately following the 38-bit ID.
  1. Hexadecimal vs. Binary Representation: A significant discovery was that the logical boundaries of these binary data segments (ID and country code) do not necessarily align neatly with hexadecimal character boundaries. This means a single hex character might contain bits belonging to both the ID and the country code, or even parts of other data fields, making direct interpretation from hex misleading. Hexadecimal is merely a representation; the true data structure lies at the binary level.
  1. Flawed Redaction Practices: The most impactful finding relates to privacy. Nash observed numerous instances online where individuals attempted to redact their pet's microchip ID by obscuring the end of the hexadecimal string. However, because the critical ID information is encoded from the beginning (left-to-right) of the binary sequence, these redaction efforts were utterly ineffective, leaving the sensitive data fully exposed. This highlights a widespread lack of understanding of underlying data encoding principles.
  1. ISO Standard Implications: While not directly referenced by number during the initial discovery, Nash later confirmed that an ISO standard (likely ISO 11784 and ISO 11785) defines how this data is structured. However, access to this standard often comes with a financial cost, creating a barrier to entry for researchers and individuals seeking to understand these systems.

These findings collectively expose vulnerabilities arising from superficial data understanding and underscore the necessity of delving into the bit-level specifics of any protocol to ensure proper data handling and security.

Technical Deep Dive

▶ Watch: Recap: How to decode pet microchip information (6:20)

Nash's journey into the technical specifics of FDx-B microchip encoding began with establishing upper and lower bounds for the data. By writing all zeros (0x00) and then all ones (0xFF) to the chip and observing the resulting ID, he confirmed a predictable range. The next step involved systematically incrementing values, one bit at a time, to identify where the ID and its "prefix" (country/manufacturer code) boundaries lay within the raw hexadecimal string.

A significant pitfall encountered early on was assuming that the hex characters would neatly correspond to distinct data fields. Nash initially focused on Most Significant Bit (MSB) first reading, a common approach in some binary contexts. However, when examining the hex, he noted inconsistencies; for example, changing a hex character might result in an ID jump, or the ID wouldn't change as expected. This led to the realization that hexadecimal is merely a compact representation of the underlying binary data, and the actual data segments (like the ID) could span across multiple hex characters.

The breakthrough came from breaking down the hexadecimal into its constituent binary nibbles (groups of four bits). By converting each hex character into its 4-bit binary equivalent, the true structure began to emerge. Nash discovered that the main ID is encoded in the first 38 bits when reading the raw binary from left to right. This left-to-right, MSB-first reading was critical, as many binary calculators default to Least Significant Bit (LSB) first, which would yield incorrect results if not accounted for. For instance, the binary 00001 (decimal 1) might be interpreted differently depending on the reading direction.

After identifying the 38-bit segment for the ID, Nash focused on the "prefix." Through further iterative testing and binary analysis, he determined that this prefix, later identified as the country code or manufacturer code, occupied the subsequent 10 bits. Critically, these 10 bits often did not align perfectly with hex byte boundaries. For example, the ID might end halfway through a hex character, and the country code would begin in the remaining bits of that same hex character, then continue into the next. This "bridging" across hex characters was a key insight, explaining why his initial attempts to find clear boundaries based on hex characters were unsuccessful.

To illustrate the decoding process, Nash provided an example:

  1. Obtain the raw hex data from the Flipper Zero or other RFID reader.
  2. Convert the hex data into binary, nibble by nibble. For example, 0x06 becomes 00000110.
  3. Identify the ID segment: Take the first 38 bits from the left.
  4. Convert the 38-bit binary string to decimal. Remember to interpret this as MSB-first. Using a calculator, this often means inputting the binary string and ensuring the conversion mode is set correctly or manually performing the calculation from left to right (2^n, where n decreases from left to right).
  5. Identify the country/manufacturer code segment: Take the next 10 bits immediately following the 38-bit ID.
  6. Convert this 10-bit binary string to decimal, again using MSB-first interpretation.

Nash explicitly noted remaining challenges: the encoding of the "bits" section (which an audience member later suggested might relate to vaccination status for certain diseases like parvovirus) and any potential temperature data (indicated by a 'T:' in some chip reads). He encouraged the audience to continue this research, highlighting the collaborative nature of security discovery. The talk also briefly touched upon the ISO standard for these microchips, which, if accessible (it typically costs money), would formally define these encoding structures. While the Flipper Zero was the tool of choice, Nash confirmed that similar analysis could be performed with other RFID tools like a Proxmark 3, although he noted the Proxmark sometimes provided even less raw hex data, making the reverse engineering potentially more challenging.

Demo / Proof of Concept

▶ Watch: Critical security finding: the redaction fail (8:10)

While "Of Microchips and Mammals" didn't feature a live, real-time hacking demonstration in the traditional sense, the entire talk served as a comprehensive proof of concept for Elliott Nash's reverse engineering methodology. The core "demo" was the methodical, step-by-step deconstruction of the FDx-B microchip encoding, which he presented as a guided journey of discovery.

The initial "proof" of concept was his successful scan of his own dog's microchip using the Flipper Zero, revealing the raw hex data and the partially interpreted ID and protocol. This initial success validated the Flipper Zero's capability and set the stage for the deeper dive. The subsequent "demonstration" then shifted to illustrating how he uncovered the encoding details. This involved visually walking the audience through his thought process, showing how he experimented with changing bits, observed corresponding changes in the interpreted ID, and ultimately realized the non-alignment of binary data with hexadecimal boundaries. He presented visual aids breaking down hex into binary and highlighting the 38-bit ID and 10-bit country code segments.

The most impactful "proof of concept" within the talk, however, focused on the critical flaw in common redaction practices. Nash presented real-world examples (likely screenshots from social media or online forums, though not explicitly stated) where individuals had posted images of their pet's microchip data, attempting to redact the ID by covering the end portion of the hexadecimal string. He then powerfully demonstrated, using the encoding knowledge he had just shared, that such redactions were completely ineffective. Because the ID is encoded in the first 38 bits (read left-to-right), covering the latter part of the hex string left the entire ID perfectly legible to anyone who understood the encoding.

To conclude this demonstration, Nash provided an example of effective redaction. He showed how one should obscure the initial portion of the hexadecimal data, corresponding to the left-to-right binary representation of the 38-bit ID and 10-bit country code, to truly protect the sensitive information. This visual comparison starkly highlighted the privacy implications of misunderstanding data encoding versus merely obscuring superficial representations. The "demo" was less about active hacking and more about educating the audience on the correct interpretation and secure handling of sensitive data, illustrating the direct consequences of his technical findings.

Defensive Implications

▶ Watch: Q&A: ISO standard and other RFID tools (11:40)

Elliott Nash's research into pet microchip encoding carries significant defensive implications for pet owners, veterinary professionals, and anyone handling sensitive identification data. The primary takeaway is a stark warning about data privacy and the illusion of redaction.

  1. Understand Data Encoding, Don't Just Obscure: The most critical defensive measure is to deeply understand how data is encoded before attempting to redact or share it. Simply blurring or blacking out parts of a hexadecimal string is demonstrably insufficient if the underlying binary structure is not understood. Defenders must move beyond superficial data representations and analyze information at the bit level. For FDx-B microchips, this means recognizing the 38-bit ID and 10-bit country/manufacturer code are read left-to-right (MSB first).
  1. Proper Redaction Techniques: When sharing images or digital representations of microchip data, ensure that the actual identifying binary segments are obscured. This means redacting the initial portions of the hexadecimal string that map to the left-to-right binary encoding of the ID and country code. Partial redaction, as Nash demonstrated, can be worse than no redaction if it creates a false sense of security.
  1. Awareness for Pet Owners and Vets: Pet owners should be aware that their pet's microchip ID, often thought to be private, can be easily read and decoded by readily available tools like the Flipper Zero. Veterinary clinics and animal shelters, which handle vast amounts of this data, should be educated on the encoding specifics to ensure they are not inadvertently exposing sensitive information when sharing data or images, even internally.
  1. Implications of Open Standards (and their cost): The existence of an ISO standard for FDx-B microchips implies a defined and public (though often paywalled) specification. Organizations and developers creating tools or systems that interact with these chips should ideally consult and adhere to these standards to ensure correct interpretation and secure handling of data. The cost barrier to accessing these standards, however, presents a challenge that could be addressed by greater industry transparency or open-source initiatives.
  1. Beyond Pet Microchips: The principles demonstrated in this talk extend to many other areas of security. Misinterpretations of data encoding, whether in network protocols, file formats, or other identification systems, can lead to critical vulnerabilities. Defenders should apply the same inquisitive, bit-level analysis to any system where data integrity and privacy are paramount.

In essence, Nash's talk serves as a call to action for greater technical literacy. It emphasizes that true defense comes not from obscuring what we don't understand, but from a profound understanding of how information is structured and processed at its most fundamental level.

Key Takeaways

  • Pet Microchip Encoding is Specific: FDx-B pet microchip IDs are encoded in the first 38 bits, and the country/manufacturer code in the subsequent 10 bits, when read left-to-right (Most Significant Bit first) from the raw binary data.
  • Hexadecimal is a Representation, Not the Raw Structure: The logical boundaries of data fields (like ID and country code) often do not align neatly with hexadecimal character boundaries, requiring bit-level analysis to correctly interpret.
  • Reading Direction Matters: Many binary tools default to Least Significant Bit (LSB) first, but FDx-B microchip data is read Most Significant Bit (MSB) first (left-to-right), a crucial distinction for accurate decoding.
  • Improper Redaction Creates False Security: Attempting to redact microchip data by obscuring the end of a hexadecimal string is ineffective, as the critical identification information resides at the beginning of the binary representation.
  • Deep Technical Understanding is Essential for Privacy: For robust data privacy and security, it is imperative to understand the underlying encoding mechanisms of protocols and data formats, rather than relying on superficial representations.
  • Tools like Flipper Zero Facilitate Discovery: Tools like the Flipper Zero empower individuals to explore and reverse engineer common technologies, revealing hidden complexities and potential vulnerabilities.

About the Speaker(s)

Elliott Nash is an IT Help Desk Analyst who presented his talk "Of Microchips and Mammals" at BSides London. This presentation marked his first conference talk, showcasing a remarkable aptitude for technical investigation and public speaking. Nash describes himself as being passionate about both hacking and animals, a unique combination that directly inspired his deep dive into pet microchip security. His talk reflected a curious and systematic approach to problem-solving, as he meticulously reverse-engineered the FDx-B protocol when existing documentation proved insufficient. Nash demonstrated an open and collaborative spirit, acknowledging the insights of his audience and encouraging further research into the unresolved aspects of microchip encoding.

Reviews

Dr. Zero (Offensive Security Researcher) — STRONG ACCEPT

This is exactly what grassroots reverse engineering looks like when you strip away the vendor bullshit. A help desk analyst refused to pay for a paywalled ISO standard, grabbed a Flipper Zero, and manually flipped bits until the FDx-B protocol surrendered its secrets. It's a fantastic, practical lesson in why assuming hex boundaries align with logical data structures will get your privacy wrecked.

Heather Calloway (CISO) — SOLID

This is a hobbyist reverse-engineering talk about pet microchips, not a briefing for your leadership team. However, the core mechanic it exposes—failing to redact sensitive data because users misunderstand the underlying encoding—is a direct parallel to enterprise data leaks. It is a competent BSides presentation that highlights a persistent flaw in how people handle data abstraction.

→ Top-rated talks at Security BSides London 2023

All talks from Security BSides London 2023