Andrew Auernheimer, known online as “weev,” has won an appeal against his conviction for exploiting a vulnerability in AT&T’s website to collect the email addresses of Apple iPad users. The 2010 incident earned him a 41-month prison sentence.

The U.S. Court of Appeals for the Third Circuit overturned the verdict on Friday, finding that the venue where Auernheimer was charged and prosecuted was not appropriate because the alleged offenses did not happen there. It did not consider the other grounds for the appeal.

In June 2010, Auernheimer, a member of a Web security group called Goatse Security, together with a man named Daniel Spitler, exploited a vulnerability on the AT&T website to collect the email addresses of 114,000 new Apple iPad owners who had registered their devices with the telecommunication provider.

The men found that the AT&T website automatically completed a log-in form with email addresses that were associated with SIM card serial numbers (ICC-ID) passed through a URL. The men built a program that took advantage of this feature to extract the email addresses of AT&T iPad users by submitting random ICC-IDs in what was essentially a brute force attack. The two men then contacted various media organizations to make the security issue public.

Spitler and Auernheimer were charged in Newark, New Jersey, with identity theft and conspiracy to violate the Computer Fraud and Abuse Act (CFAA). Spitler pleaded guilty and received probation, but Auernheimer unsuccessfully fought the charges in a jury trial and was sentenced to 41 months in prison, a sentence that he began serving in March 2013.

Auernheimer’s defense team, which included Hanni Fakhoury, a staff attorney at the Electronic Frontier Foundation, argued that accessing a publicly available website does not constitute unauthorized access to a computer system under the CFAA and that he shouldn’t have been charged in New Jersey.

On Friday, the federal appeals court agreed that the venue for the case hadn’t been appropriate and ordered Auernheimer released from prison.

“Although this appeal raises a number of complex and novel issues that are of great public importance in our increasingly interconnected age, we find it necessary to reach only one that has been fundamental since our country’s founding: venue,” the appeals court said in a written opinion. “New Jersey was not the site of either essential conduct element. The evidence at trial demonstrated that the accessed AT&T servers were located in Dallas, Texas, and Atlanta, Georgia. In addition, during the time that the conspiracy began, continued, and ended, Spitler was obtaining information in San Francisco, California, and Auernheimer was assisting him from Fayetteville, Arkansas. No protected computer was accessed and no data was obtained in New Jersey.”

In a statement on the EFF site, Fakhoury said that Auernheimer’s prosecution “presented real threats to security research” and that he hopes the appeals court’s decision will reassure the security community.