In recent years, the results of Chinese espionage within the United States have become increasingly apparent within their growing defense industry. Fifth-generation fighter platforms based directly off of stolen plans for America’s F-22 Raptor and F-35 Joint Strike Fighter and the recent revelation that Chinese hackers made off with 600 gigabytes of classified data relating to America’s undersea warfare efforts in June proved conclusively that Chinese spying on the American defense apparatus is alive and well. Despite our acute awareness of Chinese spying efforts within the United States, however, little discussion is devoted to American espionage efforts within China — and for good reason: most, if not all, American intelligence assets in China were executed in 2010 and 2011.

While the exact number of informants that were identified and killed varies from source to source and has not been confirmed by the U.S. government, it is believed that somewhere between 12 and more than 30 CIA assets were discovered, detained, and summarily executed by the Chinese government in the short two year span, crippling America’s intelligence apparatus within the nation for years to come. While this is no revelation, recent disclosures from CIA officers have shined a light on how America lost its intelligence foothold in perhaps its greatest diplomatic opponent of the modern era, and what they have to say is troublesome.

There has never been any doubt that working for the CIA in a nation like China is a risky endeavor. Despite China’s polished foreign policy and outward facing image, the controlling regime exercises a great deal of authority over its people, limiting access and even interactions on the internet and silencing dissenting voices from within the populous through intimidation and even violence. For those operating within China, there must have been a sense that getting caught would mean a death sentence but when all of America’s network of informants began disappearing, it became clear that something had gone terribly wrong.

“You could tell the Chinese weren’t guessing. The Ministry of State Security [which handles both foreign intelligence and domestic security] were always pulling in the right people,” one of the officials said. “When things started going bad, they went bad fast.”

A great deal of money exchanged hands as CIA case officers distributed cash to agents operating within China during this purge, allowing some the opportunity to escape the nation before Ministry of State Security officers were able to find them. According to multiple statements provided by CIA officers, every agent or asset detained by the Chinese following this breach was executed.

The breach, it turns out, began with the covert digital platform officers used to communicate with assets. Traditionally speaking, two systems are employed in such circumstances: one used through the development of an asset, while the case officer vets and assesses them, and a second communications platform kept entirely independent from the first. This separation of communications systems is intended to keep the greater network of vetted assets and agents insulated from potential security risks brought about through the development of new informants. However, it now appears that the systems being employed in China in 2010 were not only interconnected but actually even had direct connections to the CIA’s own website. Once Chinese officials gained access to the platform, they were able to quickly identify multiple other assets throughout their nation and rapidly take them into custody.

However, that significant breach of security does not account for everyone killed by the Chinese during the two-year span of time. Instead, it seems likely that Chinese intelligence officers used the network identified through the communications platform to identify working assets and agents, then followed them to identify others that were not a part of the system breach. It remains unclear how Chinese authorities gained access to the system, though it could potentially have happened in a number of ways.

There’s a high likelihood a former CIA officer named Jerry Chun Shing Lee aided the Chinese in gaining access. He was indicted on espionage charges earlier this year after it was revealed that he had accepted hundreds of thousands of dollars worth of payments from the Chinese government, however, the CIA’s use of a communications platform originally designed for operations in the Middle East shares some of the blame. As compared to China, the Middle East is not a heavily contested digital environment. China’s strict control over its own population, particularly in the digital sphere, makes the use of such a system a questionable decision at best.

It seems that it was a collection of errors, rather than one specific decision, that led to the execution of the majority of America’s intelligence apparatus within China — but it’s difficult to glean the lessons that may be learned from this calamity. While the digital systems employed by the CIA within China at the time were poorly chosen, no digital system can ever be deemed truly impenetrable. Further, it will likely take years to develop a network of intelligence gathering assets within China again, and by that time, the battle space may have evolved significantly. One thing, however, is certain: the stakes involved in international espionage today are no less dire than they were at the height of the Cold War, and the Chinese intelligence purge of 2010 and 2011 set the American security endeavor back significantly.