How algorithms can help beat ISIS

Mr. Farid worked with Microsoft to solve both problems—detection and replication. He coded a tool called Photo DNA that uses “robust hashing” to sweep for child porn. “The hashing part is that you reach into a digital image and extract a unique signature. The robust part is if that image undergoes simple changes, the fingerprint shouldn’t change. When you change your clothes, cut your hair, as you age, your DNA stays constant,” he says. “That’s what you want from this distinct fingerprint.”

The algorithm matches against a registry of known illegal signatures, or hashes, to find and delete photographs, audio and video. Photo DNA is engineered to work at “internet scale,” says Mr. Farid, meaning it can process billions of uploads a day in microseconds with a low false-positive rate and little human intervention.

Monitoring by Photo DNA, which is licensed by Microsoft at no cost and now used in most networks, revealed that the nature of the problem was “not what we thought it was,” says Ernie Allen, the retired head of the National Center for Missing and Exploited Children. Child pornography was far more widely circulated than law enforcement believed. “Hany Farid changed the world,” Mr. Allen adds. “His innovation rescued or touched the lives of thousand of kids, and uncovered perpetrators, and prevented terrible revictimization as content was constantly redistributed.”

Mr. Farid linked up with the Counter Extremism Project to apply the same robust-hashing method to extremist propaganda. But this effort has encountered resistance.