July 9, 2010, By PETER BAKER, CHARLIE SAVAGE and BENJAMIN WEISER - The New York Times. WASHINGTON — On a Friday afternoon in mid-June, President Obama sat down with advisers in the Oval Office and learned that the F.B.I. planned to round up the largest ring of Russian sleeper agents since the cold war. After discussion about what the agents had done, the conversation turned to the fallout: what to do after the arrests?

In that moment was born a back-to-the-future plan that would play out four weeks later, a prisoner exchange with surreal and even cinematic overtones as Russian and American airplanes met on a sunny tarmac in the heart of Europe on Friday to trade agents and spies much as had been done during a more hostile era.

From the first time the president was told about the case on June 11 — 16 days before the Russian agents were actually arrested — a swap emerged as an option that could resolve a potentially volatile situation without undercutting Mr. Obama’s effort to rebuild Russian-American relations. The Russian spy ring would be broken, the Americans would secure the release of four Russian prisoners and both sides could then put the episode behind them.

Administration officials said Friday that the arrests were not made for the purpose of making a deal and that no decision about a swap was made until after the agents were in custody. But they described a fast-moving sequence of events after the arrests in which both sides scrambled to reach an agreement, even to the point of Russian officials’ offering money and other benefits to encourage one of their sleeper agents to consider the deal.

The officials described the episode as perhaps the most serious test yet of the new relationship, as well as a sign of its enduring complexity.

By Friday afternoon, the 10 Russian sleeper agents arrested in American cities and suburbs were flown back to Moscow, while four men released from Russian prisons were taken from the transfer point in Vienna to London. Two of them, Igor V. Sutyagin and Sergei Skripal, got off there, and the remaining two, Aleksandr Zaporozhsky and Gennadi Vasilenko, flew on to Dulles International Airport just outside Washington. The children of the sleeper agents all left with their parents or were preparing to join them, officials said.

The lawyer for one of the freed Russians called it “a historic moment” that she had long suspected would come. “It has to do with the relations between the two countries, and with political games going on at the top,” said the lawyer, Maria A. Veselova, who represented Mr. Zaporozhsky, a former Russian intelligence agent. “It is always connected with these chess games.”

The games have been played for years, and this one was no exception. The F.B.I. had been monitoring the Russian sleeper agents as far back as a decade, and along with the C.I.A. and the Justice Department, gave the first detailed briefing to the White House in February, American officials said.

By late May and early June, counterespionage officials grew concerned that several of the agents were planning to leave the country this summer and concluded that they would have to arrest them.

At the Southern District of New York, prosecutors pulled out files on the case and completed a 37-page complaint, describing the agents’ activities, the sophisticated intelligence technology they used, and the F.B.I.’s extensive and long-term surveillance in unusual detail. A version of the document sat for years in a classified safe in New York, updated and rewritten by Michael Farbiarz, the lead prosecutor, as new evidence was developed, ready to be used whenever necessary.

“The value of a complaint like that is that you show immediately that you’ve got them dead to rights,” said David S. Kris, assistant attorney general for national security. “It showed the defendants and the Russians that we’ve got the goods. We’re not bluffing here. We’ve had you under investigation for quite a while. We’ve been in your houses, we’ve done surveillance and we have got plenty. That obviously helps things move quickly.”

Before they moved on the arrests, though, they had to tell the president. Mr. Obama was preparing to host the Russian president, Dmitri A. Medvedev, at the White House on June 24, so any arrests were bound to be politically explosive. The president’s homeland security and counterterrorism adviser, John Brennan, led the June 11 Oval Office briefing, at which officials described who the agents were, what would be in the complaint and what they would be charged with.

“There was a full discussion about what was going to happen on the day after,” said one senior White House official, who spoke on the condition of anonymity to describe internal discussions. Mr. Obama then had a meeting on the case with his National Security Council on June 18, just six days before Mr. Medvedev’s visit.

The visit went off without any discussion of the case, White House officials said, but three days later, the F.B.I. arrested 10 agents, a sweep that made headlines as a relic of the cold war. The administration moved quickly to keep the arrests from provoking the traditional volley of angry denunciations and retaliations, contacting Moscow to indicate the depth of the evidence and its willingness to resolve the situation.

Russian officials responded by removing an initial statement calling the charges “baseless” from the Foreign Ministry Web site and issuing a new one acknowledging that some of those arrested were Russian citizens. American officials were struck by the tempered remarks by Prime Minister Vladimir V. Putin, a former K.G.B. colonel, during a meeting with former President Bill Clinton.

Led by Mr. Brennan, the White House held daily 7:30 a.m. teleconferences with various agencies and quickly agreed to a swap. Officials came up with a list of four Russians who had been convicted of illegal contacts with the West and whom they wanted freed: Mr. Zaporozhsky and two other former Russian intelligence officers, Mr. Skripal and Mr. Vasilenko, as well as an arms control researcher, Mr. Sutyagin.

Peter Baker on the spy exchange between the United States and Russia.

Related

Intrigue and Ambiguity in Cases of 4 Russians Sent to West in Spy Swap (July 10, 2010)

Vienna Still a Spot for Cloak-and-Dagger Work (July 10, 2010)

Time to Wake Up, Sleeper Spy (July 11, 2010)

Times Topic: Russian Spy Ring (2010)It helped that after years of American surveillance there was little indication that the Russian agents had actually done any serious damage. Even the Justice Department did not complain about a deal because spy cases are often handled this way.

The C.I.A. was assigned to make the approach to the S.V.R., the Russian foreign intelligence agency, on June 30, less than three days after the arrests, according to an administration official. The same day, Under Secretary of State William J. Burns met with the Russian ambassador, Sergei I. Kislyak, and discussed the spy case.

The Russians considered the swap for two days and then agreed to negotiate. Leon E. Panetta, the C.I.A. director, negotiated the details with his S.V.R. counterpart, Mikhail Y. Fradkov, in three phone calls, sealing the deal on July 3. As part of the deal, Moscow agreed there would be no retaliatory action against Americans living in Russia.

Nikita V. Petrov, a historian of Russian security services, said Moscow agreed to the deal “to save face” after the embarrassment of the arrests. The episode showed the contemporary Russian intelligence service’s weakness, he said. “This was anachronistic Soviet methods.” And Russia could say American interest in the four imprisoned Russians confirmed their convictions.

But there was still the matter of convincing the prisoners who were to be exchanged. Mr. Sutyagin, for one, had long maintained his innocence and was reluctant to sign the confession that the Russian government required for his release. Even after he did, he said he was not guilty.

Likewise, the Russian agents in the United States had been trained not to admit they were spies or even Russians. But that facade soon crumbled after the Russian government acknowledged their citizenship. Soon afterward, the Russian Consulate requested meetings with them.

Not all of them were eager to make a deal, particularly those with children. Vicky Peláez, a journalist in New York, was promised that she could go to her native Peru or anywhere else in the world and would be given free housing and a monthly $2,000 stipend for life. She signed on, the last to do so, just hours before the court hearing on Thursday that completed the deal.

“Her biggest concerns were: ‘What’s going to happen to me? What are my children’s lives going to be like? Are they going to be able to come see me?’ ” said her lawyer, John M. Rodriguez. He said the Russian promises helped to “cushion the circumstances,” but were not what induced her to accept the deal.

Hours later, she and the others were whisked to La Guardia Airport and flown aboard a chartered Vision Airlines jet to Vienna. Within minutes of each other, about 11:15 a.m. local time, first the Russian plane and then the American plane landed. The prisoners switched planes and the Russian jet took off at 12:38 p.m. The American plane was in the air less than 10 minutes later.

Peter Baker and Charlie Savage reported from Washington, and Benjamin Weiser from New York. Reporting was contributed by Mark Landler from Washington, Nicholas Kulish from Vienna, and Ellen Barry, Andrew E. Kramer and Michael Schwirtz from Moscow.