For consumers looking to secure their data against snoopers – like hackers looking for your bank account or the NSA trying to read your emails – researchers may have found a solution that's as close as your smartphone. 

Cryptography, the art of writing and solving codes, is how data is securely transmitted online. From a credit card purchase on Amazon to an email sent to a friend, data is encoded so that it can only be read with a specific key, a very long string of numbers designed to thwart theft or interception.

Computer programs can generate keys, but it’s hard for them to come up with a truly random string, since software only follows instruction. A program is not truly random, but rather generates numbers using the process as it was programmed to, which means it can be reproduced by another program.

quantum numbers Researchers have found a way to use a smartphone camera to generate immensely long strings of random numbers at the quantum level -- the key to encrypting data transmitted online. Photo: University of Geneva

But researchers at the University of Geneva recently announced they've developed a method of generating random numbers using a smartphone’s camera.

The team used a Nokia N9 smartphone, which carries a basic 8-megapixel camera sensor, according to arXiv, a scientific paper collection put together by the Cornell University Library. Since cameras are able to interact with light, they can be made to generate a truly random number using quantum physics. 

The smartphone camera, when pointed at any source, can measure the amount of light it currently detects for each pixel in its field of view. Each pixel is then translated into a random number, allowing the program to create random strings at a high rate – roughly 1 megabit every second. The researchers say they had to make sure that the string was not tainted by pixels at “full saturation,” meaning a pixel was at maximum brightness.

According to the researchers, since the random numbers can be generated at a speed of 1 megabit per second, the software can be used to encrypt emails, credit transactions “and even phone calls.”

“Quantum random number generators (QRNGs) can significantly improve the security of cryptographic protocols, by ensuring that generated keys cannot be predicted. However, the cost, size and power requirements of current QRNGs has prevented them from becoming widespread,’ the researchers wrote.

Follow Reporter Thomas Halleck on Twitter