By Andrew Osborn

LONDON (Reuters) - Two of British Prime Minister David Cameron's most senior aides pressed the Guardian newspaper to hand over or destroy intelligence secrets leaked by Edward Snowden, political sources said on Wednesday.

News that Cabinet Secretary Jeremy Heywood and National Security Adviser Kim Darroch were involved drags Cameron into a storm over Britain's response to coverage of leaks from the fugitive U.S. intelligence contractor - a response that left even its U.S. ally talking of the importance of media freedom.

Cameron, on holiday in Cornwall, made no immediate comment.

The Guardian, media freedom activists and human rights lawyers say pressure on the paper over the Snowden material and the separate detention of the partner of a Guardian journalist on Sunday represented an assault on independent journalism.

The government says its intelligence agencies act within the law and that the Snowden leaks, which revealed U.S. and British surveillance of global communication networks, threaten national security. The United States has brought espionage charges against Snowden, who has found temporary asylum in Russia.

Guardian editor Alan Rusbridger said on Tuesday that he had been approached weeks ago by "a very senior official claiming to represent the views of the prime minister" and by "shadowy Whitehall figures", a reference to London's government district.

Rusbridger said he had been told the paper would face legal action if it refused to destroy or hand over data from Snowden.

Later, two intelligence agents oversaw the destruction of hard drives at Guardian offices, but Rusbridger said this would not stop reporting as there were copies elsewhere in the world.

A White House spokesman said on Tuesday that it was hard to imagine U.S. authorities taking such action against a media organization, even to protect national security.

Several sources said Heywood and Darroch were among those who had contacted the paper. Heywood is Britain's most senior civil servant and Cameron's top policy adviser; Darroch is the prime minister's senior adviser on national security issues.

"The prime minister asked the Cabinet Secretary to deal with this matter, that's true," one source told Reuters.

"You won't be surprised to hear that (Darroch) also got involved with this," said another source.

Home Secretary Theresa May, the interior minister, defended the government's actions.

"I think issues of national security are rightly addressed at an appropriate level within government, and I do not find it surprising that someone at a very senior level within government should be involved in this particular issue," May told the BBC.

"STOLEN INFORMATION"

Deputy Prime Minister Nick Clegg, leader of the Liberal Democrats in the coalition with Cameron's Conservatives, said through a spokesman it was "reasonable" for Heywood to request that the Guardian destroy data that "would represent a serious threat to national security if it fell into the wrong hands".

"The deputy prime minister felt this was a preferable approach to taking legal action. He was keen to protect the Guardian's freedom to publish, whilst taking the necessary steps to safeguard security," Clegg's spokesman said.

Rusbridger's revelations about the phone calls from the heart of government and the destruction of data have amplified a controversy over the detention at London's Heathrow airport on Sunday of David Miranda, the partner of a Guardian journalist.

Miranda, a Brazilian who was in transit from Berlin to Rio de Janeiro, was held for nine hours under an anti-terrorism law before being released without charge minus his laptop, phone and memory sticks.

He is the partner of Glenn Greenwald, a Rio-based American who has led the Guardian's coverage of intelligence secrets leaked by Snowden. Miranda had been ferrying documents between Greenwald and a Berlin-based journalist contact of Snowden.

It was unclear what information the documents contained.

Gwendolen Morgan, Miranda's lawyer, said there would be a hearing at London's High Court on Thursday to rule on her request for an urgent injunction to prevent the British authorities from examining any data seized from her client or sharing it with anyone else.

"The purpose of these proceedings is to protect the confidentiality of the sensitive journalistic material that was seized," Morgan said in her request submitted to the court.

Public opinion is divided over the issue. A poll released by YouGov on Wednesday showed 66 percent of those asked supported the police having the powers that were used to detain Miranda, but 44 percent of respondents believed the law had been used inappropriately in his case.

"The picture of a country split down the middle extends to the actions of the Prime Minister and the Guardian over the hard drives containing Mr Snowden's information," YouGov said in a statement.

"43 percent thought Mr Cameron was right to instruct the intelligence agencies, via the Cabinet Secretary, to seek to recover the hard drives, while 40 percent think that either he should have stayed out of the decision or that the action was wrong whoever authorized it."

The pollster said the public was also split on whether the Guardian had been right to publish Snowden's information.

Brazil has said Miranda's detention had "no justification", while Miranda has launched a personal legal action against the police and the government, accusing them of abusing anti-terrorism powers to get hold of sensitive journalistic material.

Russia, a frequent target of British criticism over human rights, accused the British government of double standards in comments by a Moscow Foreign Ministry spokesman.

But May said: "It is the duty of government to protect the public, and it is absolutely right, if the police believe that somebody has in their possession highly sensitive stolen information that could help terrorists, that could lead to a loss of lives, it's right that the police should act."

(Additional reporting by Mark Hosenball in Washington; and Costas Pitas and Michael Holden in London; Writing by Estelle Shirbon; Editing by Guy Faulconbridge, Alastair Macdonald and Will Waterman)