The US Justice Department is expected to withdraw its legal action in California seeking to force Apple to unlock an encrypted iPhone used by one of the San Bernardino shooters, a law enforcement official familiar with the situation said.

Apple declined to immediately comment. 

Apple has been fighting a court order obtained by the Federal Bureau of Investigation last month, which required the company to write new software to disable password protection and allow access to the phone used by one of the San Bernardino, California shooters, Syed Rizwan Farook.

US officials said last week that they were hopeful they would be able to unlock the iPhone without help from Apple.