A federal judge on Tuesday ordered Apple to give investigators access to encrypted data on the iPhone used by one of the San Bernardino shooters, assistance the computer giant “declined to provide voluntarily,” according to court papers.

In a 40-page filing, the U.S. Attorney’s Office in Los Angeles argued that it needed Apple to help it find the password and access “relevant, critical … data” on the locked cellphone of Syed Farook, who with his wife Tashfeen Malik murdered 14 people in San Bernardino, California on December 2.

“Despite … a warrant authorizing the search,” said prosecutors, “the government has been unable to complete the search because it cannot access the iPhone’s encrypted content. Apple has the exclusive technical means which would assist the government in completing its search, but has declined to provide that assistance voluntarily.”

Syed Farook and Tashfeen Malik arrive in Chicago on July 27, 2014. U.S. Government

Get breaking news and insider analysis on the rapidly changing world of media and technology right to your inbox. This site is protected by recaptcha

Prosecutors said they needed Apple’s help accessing the phone’s data to find out who the shooters were communicating with and who may have helped plan and carry out the massacre, as well as where they traveled prior to the incident.

The judge ruled Tuesday that the Cupertino-based company had to provide “reasonable technical assistance” to the government in recovering data from the iPhone 5c, including bypassing the auto-erase function and allowing investigators to submit an unlimited number of passwords in their attempts to unlock the phone. Apple has five days to respond to the court if it believes that compliance would be “unreasonably burdensome.”

In a statement, United States Attorney Eileen M. Decker called the move an "important step."

“Since the terrorist attack in San Bernardino on December 2, 2015, that took the lives of 14 innocent Americans and shattered the lives of numerous families, my office and our law enforcement partners have worked tirelessly to exhaust every investigative lead in the case," said Decker. "We have made a solemn commitment to the victims and their families that we will leave no stone unturned as we gather as much information and evidence as possible. These victims and families deserve nothing less. The application filed today in federal court is another step — a potentially important step — in the process of learning everything we possibly can about the attack in San Bernardino."

After the shooting at the Inland Regional Center in San Bernardino, authorities said they recovered several cell phones Farook and Malik had tried to destroy and had dropped in a waste bin. The iPhone referenced in the judge’s ruling was found in a black Lexus belonging to Farook’s family.

An iPhone 5C is displayed during an Apple product announcement at the Apple campus on September 10, 2013 in Cupertino, California. Justin Sullivan / Getty Images file

The iPhone is owned by Farook's employer, the San Bernardino County Department of Public Health, which assigned it to him. The county consented to investigators' requests to search its contents.

Prosecutors argued evidence in Farook’s iCloud account indicates that he was in communication with victims whom he and his wife later shot, and phone records show Farook communicated with Malik using his iPhone.

Prosecutors alleged in their filing that Farook may have disabled the iCloud data feature to hide evidence. Although investigators have been able to obtain several backup versions of Farook’s iCloud data, the most recent version they’ve been able to access dates from about a month and a half before the shooting. They said this showed Farook “may have disabled the feature to hide evidence."

Last week FBI Director James Comey referenced the San Bernardino shootings when testifying before Congress about the challenges posed by technology that allows cell phones to lock with no apparent means of override. The new court documents give some details about those hurdles and the ongoing investigation.

Apple did not immediately respond to a request for comment.