Terrorist groups around the world have changed their methods of operating in direct response to disclosures by the former US intelligence operative Edward Snowden, Britain's spymasters have warned.
MI6 chief Sir John Sawers said al Qaida were "rubbing their hands with glee" at the exposure of the surveillance methods used by GCHQ - Britain's electronic eavesdropping agency - and its US counterpart, the National Security Agency.
Sir Iain Lobban, the director of GCHQ, said that in the five months since Mr Snowden's revelations started appearing in the media, they had monitored terrorist groups discussing in "specific terms" how to avoid communications systems they now considered to be vulnerable.
Sir John and Sir Iain were giving evidence alongside MI5 director-general Andrew Parker in an unprecedented first public appearance by the heads of the three agencies before the parliamentary Intelligence and Security Committee.
In a dramatic 90-minute hearing at Westminster, they insisted that they operated at all times within the framework of the law and did not engage in mass "snooping" against ordinary citizens.
They made plain their anger at the damage which they said had been done to national security as a result of Mr Snowden's leaks to the media.
Sir Iain suggested they could help serious criminals and even paedophiles avoid detection as the success of surveillance operations depended upon the targets being "unaware or uncertain" of the methods being used against them.
When those methods were made public, the effect, he said, could be a "sudden darkening" of the intelligence picture.
"More often it is gradual, but it is inexorable. What we have seen over the last five months is near daily discussion amongst some of our targets," he said.
"We've seen terrorist groups in the Middle East, in Afghanistan and elsewhere in south Asia discussing the revelations in specific terms, in terms of the communications packages that they use, the communications packages that they wish to move to.
"We have actually seen chat around specific groups, including closer to home, discussing how to avoid what they now perceive to be vulnerable communications methods, or how to select communications which they now perceive not to be exploitable."
Asked whether the discussions related directly to the recent revelations about surveillance, Sir Iain said: "It is a direct consequence. I can say that explicitly."
Sir John said the leaks had been "very damaging", putting operations at risk and making it more difficult to recruit agents in dangerous situations abroad.
"It is clear that our adversaries are rubbing their hands with glee, al Qaida is lapping it up," he said.
"We've an extraordinarily difficult task. We have to identify and recruit agents in the most exposed places - in the higher reaches of al Qaida, in the countries that are trying to do our country harm, secret states that are trying to do damage to us.
"We need to have the possibility of examining the intelligence, of drawing information that our partner agencies have, in order to identify those very brave individuals that are prepared to work with us against their undemocratic, secretive, oppressive societies, which cause us threat.
"If you end up diminishing our ability to use technology, we will be less able to have that advantage we have and our country will be less safe."
Mr Parker said MI5 relied heavily upon the ability of GCHQ to intercept terrorist communications to disrupt plots in the UK.
"The advantage that we have as intelligence agencies that leads to that sort of opportunity can be fragile and if we lose it then we are just making a very difficult task even harder," he said.
Following the hearing, committee chairman Sir Malcolm Rifkind said Sir Iain had not mentioned in previous closed evidence that GCHQ had eavesdropped on terrorists discussing changing their methods.
"That's something that must have happened very recently, that they've got that hard evidence," he said.
Sir Iain acknowledged there was an "active" discussion as to whether GCHQ could publicly say more about its operations, but insisted it was not engaged in the mass monitoring of communications of ordinary citizens.
''We do not spend our time listening to the telephone calls or reading the emails of the majority, the vast majority that would not be proportionate, it would not be legal. We do not do it," he said.
Sir Iain described the internet as an ''enormous hayfield'' where GCHQ was trying to access ''those parts of the field that we can get access to and which might be lucrative in terms of containing the needles or the fragments of the needles we might be interested in, that might help our mission''.
He said they did not employ the type of people who would would be prepared to intrude into the private lives of ordinary people.
''If they were asked to snoop I wouldn't have the workforce, they'd leave the building,'' he said.
The Guardian, which has published many of Mr Snowden's leaks in the UK, defended its actions while expressing surprise that the agency was not questioned about his detailed disclosures.
"The disastrous loss of classified data was not the responsibility of journalists but of the intelligence community itself. It is only the involvement of global newspapers that prevented this information from spilling out across the web and genuinely causing a catastrophic leak," the newspaper said in a statement.
"We understand that the agencies will always warn that any form of disclosure has a damaging impact on their work - but this cannot mean the end of all questioning and debate."