Theresa May, the home secretary, has dismissed a warning by the former lord chancellor Lord Falconer of Thoroton that the Metropolitan police had no legal basis to detain David Miranda under the Terrorism Act 2000.

After a warning from Falconer that the authorities had "incompetently" used the wrong law to detain Miranda, the home secretary said that the police had acted within the correct "framework".

But May used highly cautious language and only endorsed the police action after being asked three times by Martha Kearney on Radio 4's The World at One about Falconer's claim that the Terrorism Act provided no legal basis to detain Miranda.

In a Guardian interview, Falconer said the act makes clear that police can only detain someone under schedule 7 to the act to assess whether they are involved in the commission, preparation or instigation of terrorism.

He told the Guardian: "I am very clear that this does not apply, either on its terms or in its spirit, to Mr Miranda."

The former lord chancellor later told The World at One that the authorities should have used an injunction – rather than anti-terror laws – if it believed that Miranda was carrying documents that contained information that could help terrorists if it fell into the wrong hands.

Falconer said: "If the government are so concerned about this – and I can understand that they might be – use the powers competently and in accordance with the law. Don't use the wrong powers and don't use them incompetently."

May initially declined to respond to Falconer's criticism. Asked by Kearney about his claim that the act provided no basis to detain Miranda, the home secretary criticised the Today programme presenter Evan Davis for suggesting earlier that the authorities were taking action to avoid embarrassment to the government.

Asked for a second time about Falconer's claim, May said that the Met had decided they were acting legally. When she was asked for a third time about Falconer's claim, May finally endorsed the police action.

The home secretary said: "It is absolutely right it is the duty of government to protect the public. 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 is right that the police should act. I believe that schedule 7 of this act enables the police to do that. It gives them the framework for that."

May declined to say what would happen to Miranda's material because he has launched a legal action. "There is potential for these matters being considered in court so I don't think it is appropriate for me to comment on that particular issue."

May also became the first member of the cabinet to respond to the disclosure that the cabinet secretary, Sir Jeremy Heywood, demanded that the Guardian destroy hard drives containing leaked NSA documents or risk legal action.

"Are you saying if [the] government believes there is information that is a potential danger to national security, that could be helpful to terrorists, that is being held potentially insecurely, that could fall into the wrong hands that government should not act on that? I take a different view."