Mohamed Mohamud appeared to have discovered an unusually compassionate pair of terrorists.

They told him he didn't have to kill to be a good Muslim. He could just pray. A bomb was a very serious matter, they said. Kids might be killed. Time and again, they offered a way out.

At a hotel in downtown Portland, Ore., in July, the two undercover FBI agents listened as Mohamud explained his dream of detonating a car bomb during the city's Christmas celebration. They offered to help, if Mohamud was sure he wanted to go through with it.

"You always have a choice," one of the agents said, according to court documents. "You understand? With us, you always have a choice."

It was not an offhand remark. It was part of a carefully scripted routine the FBI has been perfecting since the September 2001 terrorist attacks. Sting operations, choreographed by FBI and Justice Department officials in Washington, have included plots against Dallas skyscrapers, Washington subways, a Chicago nightclub and New York's John F. Kennedy International Airport.

The plots have all been fictional. The intent, the FBI says, has been real. And the government has a string of convictions to back that up, a track record that has made undercover stings one of the government's go-to strategies in terrorism cases.

But the tactic is not without its critics. Each arrest has been followed by allegations of entrapment and claims that the government is enticing Muslims to become terrorists, selling them phony explosives, then arresting them.

As Mohamud appeared in court on a terrorism charge Monday, friends accused the FBI of luring him into a plot the government had concocted.

"If you talk with someone enough, they'll be convinced they need to do something," said 20-year-old Muhahid El-Naser. He was among a small number of people gathered outside a federal court building about a five-block walk from what the government alleges was the target of the bomb plot last week, Pioneer Courthouse Square.

No terrorism case since 9/11 has been thrown out because of entrapment. Just last month, the tactic passed its latest test when a New York jury convicted four men of trying to blow up synagogues. Jurors rejected the argument that the FBI enticed the men into a plot they never would have come up with otherwise.

"When the government supplies a fake bomb and then thwarts the plot, this is insanity. This is grandstanding," Susanne Brody, one of the defense attorneys in that case, said Monday when asked about the FBI's use of undercover stings.

Brody said the tactic requires extraordinary amounts of time and money and can ensnare hapless people, not hardened terrorists.

"The people they repeatedly come up with continue to be people who have no ability to do something on their own," said Samuel Braverman, another defense attorney in the New York case who said he's skeptical of a strategy that amounts to "picking off the dumbest we have to offer."

In the Oregon case, even the government's own documents paint Mohamud as something of a piddling terrorist: He tried to connect with a jihadist in Pakistan, but kept mistyping the e-mail address. He claimed that, because he had been a rapper, he could get an AK-47 machine gun.

And while his online writing suggested exercise routines for would-be terrorists — jump rope, run in the sand, jog before dawn so you're not afraid of the dark — he confided to undercover FBI agents that he didn't know how to be a terrorist and needed training.

Counterterrorism officials don't buy the argument that a wannabe terrorist is less of a concern. They say the only difference between someone like Mohamud and someone like Faisal Shahzad, who admitted trying to set off a bomb in Times Square this spring, is that the FBI got to Mohamud before he could be trained to pull off an actual attack.

After all, Mohamud also made it clear he wanted to carry out an attack and rejected every opportunity to change his mind, officials said.

"He was told that children — children — were potentially going to be harmed," Attorney General Eric Holder said Monday, rejecting the notion that FBI agents entrapped Mohamud.

In Oregon, the FBI went so far as to load a van full of phony explosives and let Mohamud try to activate them during the Christmas tree lighting celebration, according to court documents. That tactic, along with the repeated offers to let Mohamud walk away, reflect how far the FBI's role-playing has come since an early, high-profile sting operation in Miami nearly fell apart.

When federal authorities unveiled that case in 2006, they said seven men from Miami's impoverished Liberty City neighborhood had planned to destroy the Sears Tower in Chicago. But the plot never got past the discussion stage and the group never had the means to carry out the attack.

The case suffered two mistrials and two men were acquitted before prosecutors finally won the case and five men were sent to prison last year.

Today, authorities are more likely to carry their ruses further, give suspects more opportunities to clearly state their intentions for FBI microphones and even let them light a fuse to a fake bomb.

"Particularly in light of cases like Liberty City, everybody at Justice and the FBI is predisposed to taking it as far as they can," said Patrick Rowan, the Justice Department's former top counterterrorism official.

Jeffrey H. Sloman, a former federal prosecutor in Miami who supervised the Liberty City case, said people caught up in stings tend to be people who have the desire to kill but are still looking for ways to pull it off. He acknowledged that leaves prosecutors open to claims that such cases are just boasts and bluster.

"It's ripe for criticism, second-guessing and Monday-morning quarterbacking, but when you're talking about people who express a desire to murder and maim large numbers of people," he said, "you have to explore that."