A federal magistrate-judge in New York City has ruled that the U.S. government can’t force Apple to hack an iPhone to investigate a drug dealer. It’s a win for Apple, which is being pressured by federal law enforcement agents to help it break into iPhones in at least 13 instances across the country. Apple says doing the federal government’s bidding would undermine the security features in hundreds of millions of iPhones around the world.

So far, the Department of Justice is relying on the All Writs Act, passed in 1789, which gives judges broad discretion in carrying out the law. But on Monday, Judge James Orenstein said federal investigators can’t use that law to pull this off. The U.S. government’s argument doesn’t justify “imposing on Apple the obligation to assist the government’s investigation against its will,” the judge wrote. Orenstein said law enforcement is inappropriately trying to use powers that it hasn’t been given by Congress. READ MORE