A senior US judge has branded the NSA's collection of phone records 'unconstitutional' and 'Orwellian'.

NSA
The NSA's mass collection of US phone records has been branded unconstitutional and Orwillian by a top US judge. Reuters

Speaking in a Washington DC court, Federal Judge Richard Leon said the National Security Agency's actions, where it was found to have collected records of both US and foreign nationals, amounted to "arbitrary invasion".

Leon said the NSA's surveillance programme - revealed by documents leaked by former contractor Edward Snowden - was "indiscriminate" and an "almost Orwellian technology that enables the government to store and analyse the phone metadata of every telephone user in the United States."

Metadata is not the audio of a phone conversation, but all information relating to the call, including the numbers calling and receiving, their location, the duration of the call, and the time and date at which it took place.

Leon continued to say the NSA's actions are "unlike anything that could have been conceived in 1979," referring to the year in which the Supreme Court first allowed the government to collect such data.

The judge was responding to a lawsuit brought by conservative legal activist Larry Klayman, a user of a Verizon mobile phone who challenged the NSA's collection of data relating to phone calls made by customers of that network.

Revealed by one of Snowden's first leaks, Verizon was found to have disclosed phone call metadata of millions of calls to the NSA where at least one party was located in the US at the time of the call.

Leon issued a preliminary injunction against the NSA surveillance programme, but suspended the order to allow for an appeal by the justice department - as a result, the programme can continue for now.

Klayman told the BBC: "If the NSA continues to do this, they're now on notice that it's illegal, and we will seek to have them held in criminal contempt of court."

In a statement provided to the journalist Glenn Greenwald, and published by the New York Times, Snowden said: "I acted on my belief that the NSA's mass surveillance programmes would not withstand a constitutional challenge, and that the American public deserved a chance to see these issues determined by open courts."

Snowden added: "Today, a secret programme authorised by a secret court was, when exposed to the light of day, found to violate Americans' rights. It is the first of many."

Commenting after the ruling, Klayman said: "I'm extremely gratified that Judge Leon had the courage to make this ruling. He is an American hero."

Klayman now hopes to turn the case into a class action lawsuit on behalf of all Americans.