Analyze partial or corrupted QR codes

hpekristiansen picture hpekristiansen · Nov 11, 2012 · Viewed 10.8k times · Source

How can I analyze broken/partial QR codes? Normally a QR decoder will just tell you that the data can not be read. This is not very useful. Even though the code is not readable, some information can, presumably, be extracted!

  • Is the finder patterns found?
  • Is the timing pattern found?
  • What is the version?
  • What is the error level?
  • What is the mask?
  • Is the format intact?
  • What is the mode?
  • Is the stop pattern found after the correct length?
  • Is there any meaningful data?

How can I extract this information from broken/partial QR codes?

Answer

SDsolar picture SDsolar · Apr 27, 2017

This is a question that comes up in many ways; some easier than others.

To answer your direct question: The tool you need: Your brain.

Software can help but to decode partial or misprinted codes takes some work. It is like detective work. You need to take what you have and fill in what you know about the way they are created in the first place, then make educated guesses for the win.


Here is a tour of the concept. By looking at these articles most of the items on your bullet-point list will be answered.

This article explains the overall format in good detail:

Wounded QR Codes

For instance, here is the first image in the article about formatting:

enter image description here


Here is a real-world example of the process of decoding a partial image:

Decoding a partial QR code

It begins with the challenge image

enter image description here

Then shows you the order of bits that are encoded:

enter image description here

Then through the process of detective work to produce the final image:

enter image description here


Here is a different problem. You have a full image but it won't scan properly so you have to decode it by hand:

Decoding small QR codes by hand

It starts out with a tattoo:

enter image description here

Which is in the wrong orientation, and also won't scan properly.

So you work through the decoding process:

enter image description here

Yielding the final result: Maci Clare Peltz


Have fun detecting!