Apple (AAPL) has vigorously defended itself against the federal government and the FBI in the San Bernardino hacking case, and one New York judge is siding with the world's most valuable company.

Federal Magistrate Judge James Orenstein has ruled the government can not force Apple to break into the iPhone password security in a similar matter, with the government trying to access meth dealer Jun Feng's iPhone. As in the San Bernardino case, the government tried to use the All Writs Act to compel Apple to cooperate, but Orenstein questioned whether the Act, passed in 1789, was sufficient and relevant enough.

The ruling could establish some precedent that could be used in the San Bernardino case.  

Apple is a holding in Jim Cramer's Action Alerts PLUS Charitable Trust Portfolio.

Exclusive Look Inside:
You see Jim Cramer on TV. Now, see where he invests his money and why Apple is a core holding of his multi-million dollar portfolio.

Want to be alerted before Jim Cramer buys or sells AAPL? Learn more now.

Feng, who has pleaded guilty of his crime, had an iPhone 5s in his house and when the government tried to access it, but Feng said he forgot his password, leading the FBI to try to coerce Apple into accessing the account.

The difference between the Feng case and the San Bernardino case, in which gunman Syed Farook used an iPhone 5c, is Feng's phone was running iOS 7, which doesn't encrypt data by default the way that newer operating systems do. In the Feng case, Apple is being asked to bypass the phone's password so that authorities can extract some of the information on it. 

Here is the key passage of Orenstein's ruling, denying the government's case:

The government seeks an order requiring Apple, Inc. ("Apple") to bypass the passcode security on an Apple device. It asserts that such an order will assist in the execution of a search warrant previously issued by this court, and that the All Writs Act, 28 U.S.C. § 1651(a) (the "AWA"), empowers the court to grant such relief. Docket Entry ("DE") 1 (Application). For the reasons set forth below, I conclude that under the circumstances of this case, the government has failed to establish either that the AWA permits the relief it seeks or that, even if such an order is authorized, the discretionary factors I must consider weigh in favor of granting the motion. More specifically, the established rules for interpreting a statute's text constrain me to reject the government's interpretation that the AWA empowers a court to grant any relief not outright prohibited by law.

Below is the entire ruling from Orenstein:

 

IN RE ORDER REQUIRING APPLE, INC

More from Technology

Qualcomm Falls After Short-Seller Argues It Will Lose FTC Case

Qualcomm Falls After Short-Seller Argues It Will Lose FTC Case

IBM: Why I'm Starting to Believe in Big Blue's Turnaround Story

IBM: Why I'm Starting to Believe in Big Blue's Turnaround Story

Tencent Content Is Not King in China

Tencent Content Is Not King in China

Blockchain, Cloud are Keys to IBM Cashing in on Consumer Trends

Blockchain, Cloud are Keys to IBM Cashing in on Consumer Trends

Micron Stock Still Too Early to Buy

Micron Stock Still Too Early to Buy