A U.K. court has ruled that information garnered by a British intelligence agency from its U.S. counterpart was obtained unlawfully.

The Investigatory Powers Tribunal (IPT) found that Government Communications Headquarters (GCHQ) access to data intercepted by the National Security Agency (NSA) encroached on European human rights law, reports the Guardian.

The case relates to the PRISM and Upstream mass surveillance programs, which came to light when NSA contractor and whistleblower Edward Snowden leaked details to the world’s media.

GCHQ’s day in court came about after civil liberty groups, including Privacy International and Liberty, argued that GCHQ receiving private communications garnered by the NSA was illegal.

It’s worth noting, however, that today’s decision relates only to historical incidents, from when PRISM was established in 2007 through to 2014. Indeed, the same tribunal ruled back in December that current laws do not violate human rights legislation, after British law was updated to ensure compliance. This forced the civil liberties group to pursue the case from a historical standpoint.

In its ruling today, the IPT said:

“We would accordingly make a declaration that prior to the disclosures made and referred to in the Tribunal’s Judgment of 5 December 2014, the regime governing the soliciting, receiving, storing and transmitting by UK authorities of private communications of individuals located in the UK, which have been obtained by US authorities pursuant to Prism and/or (on the Claimants’ case) Upstream, contravened Articles 8 or 10 ECHR, but now complies.”

For the uninitiated, Article 8 covers the right to a private life, while article 10 covers freedom of expression. But what’s perhaps most notable here is that this ruling represents the first time the IPT, which was founded in 2000, has judged against any U.K. intelligence agency.

However, GCHQ was quick to put a positive spin on things, saying that the IPT merely found against the Government in “one small respect” relating to the disclosure of two paragraphs. A spokesperson said:

“We are pleased that the Court has once again ruled that the UK’s bulk interception regime is fully lawful. It follows the Court’s clear rejection of accusations of ‘mass surveillance’ in their December judgment.”

As GCHQ put it, the ruling is simply about the amount of detail that was in the public domain, vis-à-vis how it worked with the NSA to monitor data. What it basically came down to was two paragraphs’ worth of information on the matter which the U.K. Government has now made public — so the GCHQ-NSA relationship remains legal.

You can read the IPT report in full here.