STAMFORD, Conn. — Three federal Transportation Security Administration officers and two other law enforcement officers were arrested on charges of accepting cash or gift cards in exchange for permitting prescription drug dealers to move tens of thousands of highly addictive painkiller pills and cash proceeds from the illegal sales through airports and highways.

The TSA officers, based at airports in Florida and New York, and a Westchester County, N.Y., police officer allowed the oxycodone through airport security, authorities said Tuesday. A Florida state trooper accepted cash and checks for ensuring dealers could freely transport the pills and cash proceeds by car through that state, prosecutors said.

“Prescription pain medication abuse is rampant in New England and this trafficking group allegedly preyed upon the addictions of individuals to line their pockets, while the law enforcement officers are alleged to have sold their badges and abused their authority to further the illegal activities of the organization,” said Steven W. Derr, special agent in charge of the Drug Enforcement Administration for New England.

The TSA officers, Christopher Allen, 45, of Palm Beach Gardens, Fla.; John Best, 30, of Port St. Lucie, Fla.; and Brigitte Jones, 48, of the Bronx, N.Y., were charged with conspiring to distribute and possessing with intent to distribute oxycodone. The New York police officer, Michael Brady, 36, and the Florida trooper, Justin Kolves, 28, face the same charges; their hometowns were not released.

Kolves also flew from Florida to New York to provide protection for what he thought was an oxycodone sale in Connecticut, authorities said.

The five, who were among 20 people arrested in connection with the alleged scheme, face up to 20 years in prison if convicted.

“In these times, no one needs to be reminded about how dangerous it is when officers who have sworn to uphold the law accept money to ‘look the other way,’” said U.S. Attorney David Fein.

Telephone messages were left with their attorneys or at possible home numbers. Best’s attorney, Matt Collins, said he had no immediate comment.

Jones’ attorney, Bill Bloss, said he anticipated Jones would plead not guilty. He said he was just appointed and has not seen the evidence yet.

The arrests stem from a DEA investigation dubbed “Operation Blue Coast.”

Authorities received information that someone possessing a large quantity of oxycodone was traveling from Palm Beach, Fla. to Stamford, Conn. to sell thousands of oxycodone pills. On April 8, the DEA arrested the man, who had about 6,000 oxycodone pills, in a Stamford hotel, prosecutors said.

The arrested man revealed that over the past year he had regularly purchased thousands of oxycodone pills from suppliers in Florida, transported the oxycodone to Connecticut by plane or car and sold the pills to Connecticut-based drug dealers. He flew from Florida to New York more than 65 times, according to an affidavit.

The man allegedly told authorities he provided cash and gift cards to certain TSA officers who screened passengers and luggage at Palm Beach International Airport in West Palm Beach, Fla., and Westchester County Airport in White Plains, N.Y, to ensure he could pass through airport security while he carried oxycodone pills. He also said he paid Brady more than $20,000 to ensure he could carry large quantities of cash from the sales through airport security.

The man said he provided cash to Kolves, the Florida trooper, and gave checks to the trooper’s fiancee, in exchange for the trooper’s assurance that individuals who transported drugs or cash would not be detained by law enforcement while driving through central Florida.

Authorities say they corroborated the allegations by recording conversations between cooperating witnesses and the arrested officers and through controlled deliveries of oxycodone, physical surveillance, and examination of rental car and airline records.

Airport security video tapes show the man handing cash to Brady, according to the affidavit. He told Jones he sells oxycodone pills, according to the affidavit.

“I don’t break the law,” he said. “I don’t rob banks.”

“Okay, there’s nothing wrong with that,” Jones said.

“High class,” the man said

“High end,” Jones said, adding later, “Your secret is safe with me.”

Jones allegedly said in another conversation with the man to let her know when he was arriving and ‘I’ll take care of the rest.”

The witness asked Kolves if he knew about problems with some pills.

“Killing people?,” Kowles asked.

“They were killing people like crazy,” the witness said. “So the government changed the law on them.”