Imagine you want to publish online an image of a document, but there are parts of it which you want to remain confidential. Maybe part of the image is somebody's phone number, or email address, or another piece of personal data that would be inappropriate to share publicly.
What should you do? You should redact the offending part of the image.
Okay, that makes sense. But how should you redact the text?
Well, a new tool makes crystal clear that it's a big mistake to redact text by pixelating it.. or indeed blurring it, or even applying a "swirl" filter.
As Dan Petro, a researcher at Bishop Fox explains, you should "never, ever, ever use pixelation for redacting text."
Petro is the author of a tool called Unredacter that can take "redacted documents" and retrieve the original words from pixelated text.
In order to do its work, all Unredacter needs to know is:
Frankly, those aren't hard to ascertain - because redacted text is rarely shown in isolation. Normally you will have a section of clear text (where the font and font size is fairly simple to ascertain) alongside a section which has been redacted through pixelation.
As he describes it, Petro's tool sees through the pixelation letter by letter - cycling through the possible letters until the most likely solution is found:
"Basically, we guess the letter “a”, pixelate that letter, and see how well it matches up to our redacted image. Then we guess the letter “b”, and so on."
As Petro explains in his blog post, the process is a little more complicated than that - and there are a number of other factors to consider for a successful reveal of the hidden text - but with the tool released, the ability to redact pixelated text has been put in the hands of anybody.
"The bottom line is that when you need to redact text, use black bars covering the whole text. Never use anything else. No pixelization, no blurring, no fuzzing, no swirling," says Petro.
So, what should you do instead of pixelation (or blurring or swirling) if you want to redact text? What you should do is ██████ out the text with an opaque black bar instead.
Just make sure that you really overwrite the text in an image, and don't make the mistake of sharing a document where the black bar effect might be undone. For instance, in the past nuclear submarine secrets have been accidentally shared in PDF files which looked like they had been redacted, but in fact could have their contents read by just clicking "copy-and-paste."
tags
Graham Cluley is an award-winning security blogger, researcher and public speaker. He has been working in the computer security industry since the early 1990s.
View all postsNovember 14, 2024
September 06, 2024