Five men from Camden, N.J., for example, were driving in January to a location in Upper Manhattan where they expected to raid a drug shipment from Miami worth about $1 million. As the police and the D.E.A. moved in on the suspects, one of the men pointed a gun at them and refused to drop it, the government has said. He was shot in the arm.

“It does obviously raise profound safety questions,” said Eugene O’Donnell, a lecturer on police studies at John Jay College of Criminal Justice. “They are moving these weapons to a particular location, and it’s not like you couldn’t have a bad ending.”

The operations in New York, conducted over the last two years, have led to more than 100 arrests and the seizure of more than 50 shotguns and revolvers, a machete, a Taser and even an AK-47, records show.

Many of the suspects have been secretly recorded during the planning of the purported robberies boasting about how they would use their weapons, court filings show. Some of the suspects said they would pose as police officers to carry out the robberies. The authorities say they have recovered New York Police Department hats and shirts, imitation police badges and handcuffs.

Federal officials defend the sting operations and say they target violent criminals who have established records of drug robberies or home invasions. The United States attorney’s office for the Southern District of New York said last month in a court filing that the investigations had been “incredibly successful in removing violent individuals and firearms from the streets.”