Intelligence chiefs at GCHQ prepared a plan to counter damaging press leaks exposing their surveillance techniques to mitigate against unfavourable coverage.
The contingency plans was contained in the latest cache of documents released by The Guardian from US whistleblower Edward Snowden.
The documents show that GCHQ did not want intercept evidence made admissible during criminal trials as this would expose their secretive techniques.
However, according to The Guardian, GCHQ did not want their methods scrutinised as this could level them open to potential court challenges.
The latest embarrassing documents showed that telecom companies assisted GCHQ “well beyond” their legal requirements.
Legal experts at the spy agency feared their snooping could leave them at risk from a privacy action under the Human Rights Act.
As part of the contingency plan, contained within the leaked documents, was to ask sympathetic senior politicians to become involved in “press handling”.
The Snowden files showed that Liberal Democrat peer Lord Carlile was on that list. Carlile this week slammed the Guardian over their coverage of GCHQ and the US National Security Agency.
In one secret memo prepared in 2009, security chiefs warned that if secret intercepts were used in court it could start a “damaging” public debate.
GCHQ was also very anxious to cover up the extent of its relationship with telephone companies – especially their ability to tap into communications being carried on overseas networks.
The Snowden revelations have caused significant diplomatic damage between the United States and the French and German governments.
However, the US has confirmed that they did not tap Prime Minister David Cameron’s phone.
Although President Obama’s administration could only assure German Chancellor Angela Merkel that they are not monitoring her phone and have no intention of doing so in the future.
Shami Chakrabarti, director of Liberty and Anthony Romero executive director of the American Civil Liberties Union issued a joint statement stating: "The Guardian's publication of information from Edward Snowden has uncovered a breach of trust by the US and UK Governments on the grandest scale. The newspaper's principled and selective revelations demonstrate our rulers' contempt for personal rights, freedoms and the rule of law.
"Across the globe, these disclosures continue to raise fundamental questions about the lack of effective legal protection against the interception of all our communications.
"Yet in Britain, that conversation is in danger of being lost beneath self-serving spin and scaremongering, with journalists who dare to question the secret state accused of aiding the enemy.
"A balance must of course be struck between security and transparency, but that cannot be achieved whilst the intelligence services and their political masters seek to avoid any scrutiny of, or debate about, their actions.
"The Guardian's decision to expose the extent to which our privacy is being violated should be applauded and not condemned."
Nick Pickles, director of Big Brother Watch, said: "The fact GCHQ has doubts about the legality of its surveillance reinforces the public interest in the disclosures about what has taken place in America and closer to home.
"Parliament never legislated to allow the scale of interception that has been exposed, with laws written long before widespread broadband internet access or Facebook existed. There is a clear and overwhelming need for a fundamental review of our legal framework and oversight mechanisms.
"If companies are handing over customer data or access to their equipment when there is no legal authority then those businesses may well have broken the law. This should be urgently investigated by the Information Commissioner."