The FBI has managed to unlock the iPhone of the San Bernardino gunman without Apple’s help, ending a court case, the US justice department says.
Apple had been resisting a court order issued last month requiring the firm to write new software to allow officials to access Rizwan Farook’s phone.
But officials on Monday said that it had been accessed independently and asked for the order to be withdrawn.
Rizwan Farook and his wife killed 14 people in San Bernardino in December.
They were later shot dead by police.
UN human rights chief backs Apple
Apple boss hits back at FBI conduct
McAfee offers to unlock iPhone for FBI
Last week, prosecutors said “an outside party” had demonstrated a possible way of unlocking the iPhone without the need to seek Apple’s help.
A court hearing with Apple was postponed at the request of the justice department, while it investigated new ways of accessing the phone.
At the time, Apple said it did not know how to gain access, and said it hoped that the government would share with them any vulnerabilities of the iPhone that might come to light.
On Monday a statement by Eileen Decker, the top federal prosecutor in California, said investigators had received the help of “a third party”, but did not specify who that was.
Investigators had “a solemn commitment to the victims of the San Bernardino shooting”, she said.
Analysis: Dave Lee, BBC North America technology reporter
A court case that had the US technology industry united against the FBI has, for the time being, gone away.
Now this debate moves into more uncertain times. The US government has knowledge of a security vulnerability that in theory weakens Apple devices around the world.
To protect its reputation, Apple will rush to find and fix that flaw. Assuming it can do that, this row is back to square one.
The court order had led to a vigorous debate over privacy, with Apple saying allowing officials access to users’ data would set a “dangerous precedent”.
The company received support from other tech giants including Google, Microsoft, and Facebook.
And earlier this month, Zeid Raad al-Hussein, the UN high commissioner for human rights, warned enforcing the order risked opening a “Pandora’s box”.
FBI director James Comey said it was the “hardest question” he had tackled in his job.
However, he said, law enforcement saved lives, rescued children and prevented terror attacks using search warrants that gave it access to information on mobile phones.