In the age of iris scans and facial recognition software, biometrics experts like to point out: The eyes don’t lie. And that has made tradecraft all the more difficult for U.S. spies.

After billions of dollars of investment — largely by the U.S. government — the routine collection and analysis of fingerprints, iris scans, and facial images are helping to ferret out terrorists and immigration fraudsters all over the world. But it has also made it harder for undercover agents to remain anonymous.

Gone are the days of entering a country with a false passport and wearing a wig and a mustache to hide your true identity. Once an iris scan is on record, it becomes nearly impossible to evade detection.

“In the 21st century, you can’t do any of that because of biometrics,” said retired Army Lt. Gen. Michael Flynn, the former director of the Defense Intelligence Agency.

On top of that, ever-present closed-circuit TV surveillance and Internet-tracking tools combine to make life even more dangerous for undercover agents. As such, the erosion of anonymity is forcing the U.S. intelligence community to rethink how it does business.

“You have to take many more security measures to be able to prepare someone to operate in an environment in which you can no longer physically hide,” Flynn said in a recent interview with Foreign Policy.

A senior Defense Department official said the policies have changed decisions about who can travel where — and how often. “It limits your movement,” said the official, who was not authorized to be named in discussing tradecraft and spoke on condition of anonymity.

At the CIA, the concerns have prompted a new era of cyber-espionage to compensate for the emerging limits on clandestine operations.

“Our ability to carry out our responsibilities for human intelligence and national security responsibilities has become more challenging,” CIA Director John Brennan said in March in announcing a major internal reorganization of the agency. It includes the creation of the Directorate of Digital Innovation, and in a memo to staff, Brennan called on the CIA to “embrace and leverage the digital revolution.”

Brennan didn’t specifically mention the impact of biometrics on covert travel, but experts say it is one of the drivers behind this organizational change.

The CIA declined to comment for this story.

California Rep. Adam Schiff, the top Democrat on the House Intelligence Committee, applauded Brennan’s new approach to the “digital domain.”

“Technology at times is a double-edged sword,” Schiff said in an email to FP. “On the one hand, advances like those in the field of biometrics make our ability to identify and track bad and dangerous actors much better.”

“On the other hand,” Schiff wrote, “these same technologies have the potential to help others track and identify us.”

Today, even criminal and terrorist organizations are using biometric systems to track their own members, Flynn said.

When it comes to counterterrorism and border security, collecting biometric data has become commonplace across the world. That wasn’t the case before the 9/11 terrorist attacks, when border agents didn’t bother with biometrics, said Terry Hartmann, vice president for security solutions and industry applications at Unisys, an information technology company.

“And now routinely, all countries are collecting as a minimum facial images of people crossing the border,” Hartmann said. “Many countries are collecting fingerprints as well. Some are collecting iris scans.”

During the war in Iraq and still in Afghanistan, the U.S. military collected biometric information from millions of people, from suspected insurgents to people applying to work on U.S. bases to everyday citizens. By lifting latent fingerprints off unexploded and sometimes even exploded handmade bombs, the military created a database of suspected insurgents and extremists in hopes of apprehending them at checkpoints and border crossings.

The United States also is collecting biometrics from Syrian rebels whom U.S. troops are training to fight the Islamic State, according to U.S. Central Command. The rebels’ information is being used in preliminary background checks and could be stored for future reference as well, should they ever be needed in terrorism investigations.

“All of the things that make it difficult to keep your identity from being disclosed also make it that much easier for us to discover others,” said Roger Mason, who served as assistant director of national intelligence for systems and resource analyses before joining Noblis, a nonprofit science and technology organization.

Among the FBI, the Defense Department, and the Department of Homeland Security, billions of dollars have been spent on biometric research and acquiring new biometric technology over the last several years.

ABI Research, a market intelligence firm, estimates that overall revenues for the global biometrics market will hit $13.8 billion this year. Recent terrorist attacks in Europe and elsewhere are expected to drive that spending even higher.

James Lewis, director of the Strategic Technologies Program at the Center for Strategic and International Studies, said biometric data collection is “irresistible to security agencies.”

Countries are realizing that “if you have a database of known terrorists and you have the ability to collect on a big population, you’re going to find people that you would otherwise not have found,” he said.

The influx of money has led to major advances in the field.

Facial recognition technology has vastly improved, with analysts now able to match images that are less than perfect. And with computer power increasing, the speed of analysis is much faster.

“Irises have gone from being a curiosity to being a mainstream biometric,” Hartmann said.

Another part of the field that is quickly growing is the collection and analysis of DNA swabs, which can come from the inside of one’s cheek, a hair follicle, or even a discarded cigarette. Because DNA matches take hours to develop, it currently is not a viable biometric for fast-moving border security checks.

DNA is used in law enforcement, and the Defense Department has collected samples on the battlefields of Iraq and Afghanistan. And, Hartmann predicted, it won’t be too long before DNA technology catches up and can be more widely used.

“It’s a lot faster than it was 10 years ago,” Hartmann said. “It took days to weeks to get a result. Now, we’re talking hours. In 10 years’ time, we’ll be talking minutes.”

While the technology has been advancing rapidly, there have only been a few rare glimpses into how biometrics collection is changing the world of clandestine operations.

In December, WikiLeaks released a secret CIA document from 2012 that gave advice to U.S. government undercover operatives traveling in and out of the European Union. It specifically describes how biometric data is collected and used, and it shows that as Europe expands its collection and introduces more-sophisticated systems, the risk to U.S. individuals traveling undercover has increased.

But the best-known example of the new spy world is the 2010 assassination of Mahmoud al-Mabhouh, a leader of the Palestinian militant group Hamas. His killing was considered a fiasco for the Israeli intelligence agency Mossad because its spies’ covers were completely blown — thanks to biometrics and surveillance technology.

The Israeli agents made a handful of mistakes throughout the mission. But crucial to their exposure was new border security and surveillance technology.

The Mossad agents had forged passports by copying the authentic ones of dual Israeli citizens from the United Kingdom, Ireland, France, Germany, and Australia, provoking widespread anger from those countries. In retaliation, Britain expelled a senior Mossad official at the Israeli Embassy in London.

As DNA and other biometric collection and analysis become more routine and more sophisticated, officials and experts said it is only going to become more dangerous for spies to operate.

“There is no simple solution to this,” Flynn said, “so we’re going to have to be far more creative than, I think, what we’re looking at right now.”