Kevin McCoy, and Jon Swartz

USA TODAY

NEW YORK — Government lawyers announced Friday night they had gained access to data on the iPhone of a New York City drug conspirator, and abruptly ended their effort to force Apple to help bypass the phone's password.

The surprise news was similar to the outcome of the previous battle to compel the tech giant's assistance in retrieving data from the iPhone of San Bernardino terror attack shooter Syed Farook.

The Department of Justice announcement came in a one-page letter to a Brooklyn federal court in a case focused on Jun Feng, a Queens, N.Y., defendant who pleaded guilty to methamphetamine conspiracy last year.

Apple rejects request to hack N.Y. drug dealer's iPhone

Federal prosecutors sought access to the phone's data in part as an effort to determine if others were involved in the alleged plot. Government lawyers wrote that a source they did not identify provided the password to Feng's iPhone, enabling investigators to key in the code by hand and access the unit's data.

Emily Pierce, Justice Department spokeswoman, said the government will no longer need Apple's assistance.

“As we have said previously, these cases have never been about setting a court precedent; they are about law enforcement’s ability and need to access evidence on devices pursuant to lawful court orders and search warrants," Pierce said. "In this case, an individual provided the department with the passcode to the locked phone at issue in the Eastern District of New York. Because we now have access to the data we sought, we notified the court of this recent development and have withdrawn our request for assistance. This is an ongoing investigation and therefore we are not revealing the identity of the individual.”

Apple declined to comment.

Apple attorneys argued last week that the FBI improperly sought the company's aid before exhausting all other means to bypass the built-in security code on the Apple-manufactured unit.

The California-based tech giant's legal team also contended the government misinterpreted provisions of the All Writs Act, the 1789 statute that Department of Justice lawyers cited as the legal basis for forcing Apple's assistance.

The legal struggle is part of a personal privacy vs. government security showdown that pits federal investigators against tech firms and cyber providers over the issue of electronic encryption.

The Brooklyn case also marks the latest legal flash point since the government withdrew a similar demand for Apple's help in obtaining data from the iPhone used by Farook. The FBI ultimately turned to an unidentified outside party that helped investigators bypass the iPhone's security without destroying material stored inside.

FBI paid at least $1.3M to hack terrorist iPhone

FBI Director James Comey earlier this week indicated the agency paid at least $1.3 million dollars for the tool that allowed it to break into Farook's iPhone 5c, which runs on Apple’s iOS 9 operating system

In the most recent case, prosecutors indicated they sought access to Feng's iPhone 5 in a bid to investigate other aspects of the alleged plot, including whether unknown others were involved.

In a March ruling, Magistrate Judge James Orenstein ruled that Apple was not legally required to help federal investigators get access to data on Feng's iPhone 5s, which runs on Apple's iOS 7 operating system. He concluded the All Writs Act didn't support "the necessity of imposing such a burden” on the company.

The Department of Justice appealed Orenstein's decision. The renewed legal arguments in the case are now being considered by Brooklyn U.S. District Judge Margo Brodie.