• On Monday, Attorney General William P. Barr asked Apple to provide access to two phones used by the shooter, but Apple declined. Apple faced a similar dispute in 2016 over access to the San Bernardino shooter's phone.
  • According to The New York Times, Apple CEO Tim Cook has reportedly gathered advisers in preparation for a potential legal battle.
  • In a tweet sent Tuesday, Trump said Apple "will have step up to the plate and help our great Country" over the issue. Apple has said it is working with the FBI on the Pensacola case.
  • Business Insider has approached Apple and the DOJ for comment.
  • Visit Business Insider's homepage for more stories.

Apple is reportedly making preparations to defy President Trump and the Department of Justice in court over the thorny issue of unlocking two iPhones used by the alleged Pensacola, Florida shooter.

The suspected shooter opened fire at the Florida naval base in early December, leaving four people including the shooter dead.

On Monday, Attorney General William P. Barr asked Apple to provide access to two phones used by the alleged shooter.

Yet Apple has refused to build a backdoor that would allow access , and, according to a report in the New York Times , the tech giant's CEO Tim Cook is said to have gathered some top advisers for what could amount to a months-long legal clash. The goal, according to the Times, would be to avoid a prolonged confrontation but the firm is prepping for a legal fight just in case.

Publicly, Apple has said it is working with law enforcement on the Pensacola case, and disputed characterizations that it isn't assisting in the investigation. Apple is also reported to be frustrated that the DOJ hasn't spent enough time using third-party tools to try and unlock the phones.

Apple's stance on refusing to compromise encryption on the iPhone jeopardizes Cook's positive relationship with Donald Trump.

In a tweet sent Tuesday , Trump wrote: "We are helping Apple all of the time on TRADE and so many other issues, and yet they refuse to unlock phones used by killers, drug dealers and other violent criminal elements. They will have to step up to the plate and help our great Country, NOW! MAKE AMERICA GREAT AGAIN."

Trump last month rubber-stamped a trade deal with China just two days before steep tariffs on many of Apple's signature products were set to go into effect.

Apple has already fought the FBI over unlocking encrypted iPhones

This is not the first time Apple has faced legal disputes over its refusal to unlock iPhones used by criminals. In 2016, it faced a bitter, months-long stand-off with the FBI over whether or not to unlock the phone used by the perpetrator of the San Bernardino shooting.

Apple's San Bernardino dispute was only resolved after a private company came forward with a way to unlock the killer's phone.

Cook and Apple have long refused to build a so-called "backdoor" into its iPhones that would allow governments to access them in cases like criminal shootings, believing this would compromise user privacy .

The US government has argued it's not up to Apple to refuse, with Barr arguing in an October speech that privacy is never an absolute right and can lawfully be violated where it's "necessary to protect the safety of society as a whole."

Business Insider has approached Apple and the DOJ for comment.

You can read the Times report here .

NOW WATCH: Watch Elon Musk unveil his latest plan for conquering Mars

See Also:

SEE ALSO: Apple has narrowly avoided a 15% tariff on the iPhone after Trump's trade deal with China