Ben Birchall/AFP/Getty Images

Mass surveillance carried out by British intelligence agency GCHQ violated the European Convention on Human Rights, a court ruled Thursday.

Judges in the European Court of Human Rights in Strasbourg, France, voted 5 to 2 that some aspects of the UK's surveillance activities violated people's right to a private life. These included indiscriminate "population-level" data collection, a lack of oversight in the collection process and the lack of safeguards to prevent the abuse of collected data.

One activity the court decided wasn't illegal, however, was GCHQ's policy of sharing sensitive data with foreign governments.

In its judgment, the court expressed particular concern over the ability of intelligence services to search and examine data that identifies senders and recipients of messages "apparently without restriction." The scope for unrestricted snooping "could be capable of painting an intimate picture of a person" through mapping of social networks and communication patterns, browsing and location tracking, and understanding who a person is interacting with, the court said.

Now playing: Watch this: Google's update makes privacy easier

The UK's bulk interception of data came to light in 2013 as part of NSA whistleblower Edward Snowden's revelations about US and UK intelligence operations. Snowden revealed a number of GCHQ spying programs, including "Tempora," which stored all internet traffic in bulk; "Karma Police," which created a web-browsing profile for every visible internet user; and "Black Hole," a repository of over 1 trillion online events, including internet histories, email and message records, and social media activity.

GCHQ, short for Government Communication Headquarters, continues to publicly neither confirm not deny the existence of programs with these codenames.

Following the revelations, a group of 14 privacy and human rights groups headed by nonprofit Big Brother Watch brought claims against GCHQ, which were heard first in the UK's Investigatory Powers Tribunal -- a special court set up specifically to hold intelligence agencies to account -- and later in the European Court of Human Rights.

The organizations that brought the case are hailing the court's decision as a landmark ruling. The decision "vindicates Mr. Snowden's courageous whistleblowing." Silkie Carlo, director of Big Brother Watch, said in a statement.

"Under the guise of counterterrorism, the UK has adopted the most authoritarian surveillance regime of any Western state," said Carlo.

A spokesman for GCHQ directed CNET's request for comment to the UK's Home Office, which did not immediately respond.

The court's ruling doesn't mean all bulk data interception by European countries is automatically illegal. Data can be legally collected in bulk if it can be justified in the interests of national security, but safeguards must be put in place. The court also didn't consider the UK's current surveillance activities or changes being introduced under the Investigatory Powers Act, which according to Carlo "poses on an even greater threat to civil liberties."

"Our work is far from over," she said.

Congress has questions: Apple, Amazon, Twitter to testify before Senate on data privacy.

A sinister connection: Cameras, surveillance and domestic abuse.