Skip to main content

To be or not to be 280 characters: All of Shakespeare’s works in a single tweet

It might sound like a plot point in a Dan Brown novel, but it’s not: A computer science undergraduate really has managed to hide the complete works of William Shakespeare, one of the world’s greatest writers, in a single tiny image that was shared in a Twitter message. Carried out by David Buchanan, a third-year student at Cardiff University in the U.K., it’s an amazing demonstration of how computers can be used to embed hidden messages in plain sight.

“Twitter filters most metadata from images, presumably for privacy and data usage reasons,” Buchanan told Digital Trends. “However, I found that ‘ICC profile’ metadata is left untouched. So I crafted an image file which also contains a ZIP archive inside its ICC profile. The ZIP file format is flexible enough that I was able to make the file simultaneously valid as a JPEG and ZIP file. For technical reasons, the contents of the ZIP file had to be split into 64-kilobit chunks, so I used a multipart RAR archive, which finally contained the text document.”

Recommended Videos

Got that? Okay, so it’s not something that most of us are going to worry about when sharing images on Twitter, but it’s an impressive demo of how much raw data can be squeezed into a tweet. By embedding a ZIP file of the complete Shakespeare into a portrait of The Bard himself, it pushes Twitter’s text limit way beyond the current 280 characters per tweet. (While we don’t know exactly how many letters are in the complete works of Shakespeare, according to the Folger Library there are 884,647 words in total.)

“There are two broad terms you could use to describe this technique,” Buchanan said. “[One is] steganography, which is the art of hiding information inside some other data. Modern-day steganography typically aims to be completely undetectable, which my technique is certainly not. A more accurate description of this technique would be a polyglot file, which is used to describe a file which can be simultaneously interpreted as multiple different data formats, depending on what software reads it.”

Buchanan said that after he found out that this could be done, he submitted it to Twitter’s bug bounty program, which pays out money to anyone who can find potential Twitter vulnerabilities that could be exploited by hackers. Twitter turned it down on the basis that it didn’t have any potential security impact, but Buchanan decided to have some fun with it nonetheless. While other people have hidden files in social media posts, Buchanan said that, to his knowledge, he is the first person to do it on Twitter.

Luke Dormehl
Former Digital Trends Contributor
I'm a UK-based tech writer covering Cool Tech at Digital Trends. I've also written for Fast Company, Wired, the Guardian…
Twitter mulls ‘trusted friends’ feature for targeted tweets
Twitter symbol photo. Credits: Twitter official.

Twitter has revealed it’s exploring new ways for users to share their tweets.

While stressing that the company hasn’t yet made working versions of any of the ideas, a designer at Twitter said that at this stage the social media company is welcoming feedback on the suggestions.

Read more
Lenovo’s new all-in-one PC features a swiveling hinge for work-from-home comfort
lenovo yoga aio 7 new monitors ces 2021 l24i 30 monitor still life

Lenovo is going all-in on products that support the new normal of working from home at next week's all-virtual Consumer Electronics Show 2021. The company unveiled a new all-in-one Yoga 7 desktop PC, as well as two new sleek monitors, the Lenovo L24i-30 and Lenovo L27e-30. The new monitors and all-in-one were announced alongside a new IdeaPad 5G and refreshed ThinkPad models.
Lenovo Yoga AIO 7

Previous

Read more
All about the tubes NASA’s Perseverance rover will use to collect Mars samples
A tray holding 39 sample tubes - each protected in a gold-colored sheath - is installed in NASA's Perseverance rover in this picture taken at the agency's Kennedy Space Center on May 21, 2020.

NASA's Perseverance Mars Rover Equipped with Ultra-Clean Sample Tubes

When NASA's Perseverance rover lands on Mars in February next year, it will begin its search for evidence of ancient life on the planet. To do this, the rover will be collecting samples of the Martian soil and rocks for analysis using its onboard instruments. But there's only so much science that can be done in a rover the size of a small car. To complete a full analysis, scientists need to get those samples off Mars and bring them back to Earth. And that means that they need to be preserved in tubes which will keep them safe over a journey of millions of miles, which may take more than a decade.

Read more