A control order imposed on a terror suspect by Home Secretary John Reid which was overturned in the courts has been restored by judges.
Mr Reid said the order was in line with human rights conventions
The Court of Appeal reversed an earlier ruling that limiting the movements of the suspect - known as "E" - contravened his human rights.
After the latest decision, Mr Reid said: "This judgement means that I can better protect the public."
But the case is now likely to be settled in the House of Lords.
The control order was originally imposed on E because the security services believed he was a facilitator and recruiter for an al-Qaeda-linked organisation, the Tunisian Fighting Group.
In February, Mr Justice Beatson at the High Court ruled that the order unlawfully deprived E of his liberty, in contravention of Article 5 of the European Convention on Human Rights (ECHR).
He also cited a failure to prosecute E in light of judgements from a Belgian court.
But in the Court of Appeal, Lords Justices Pill, Wall and Maurice Kay overturned the February judgement.
They said: "We consider it was wrong to describe the Belgian court judgments as evidence giving rise to a realistic possibility of prosecution."
After the latest ruling, Mr Reid said: "The Court of Appeal has endorsed our view that the obligations in that order did not constitute a deprivation of liberty under Article 5 ECHR.
"I am pleased too that the court accepted that the possibility of prosecution not being kept properly under review would not justify quashing the order in this case."
Now the order has been restored, E is required to stay at an address between the hours of 0700 and 1900.
He is not allowed to see unauthorised visitors at the address, have a mobile phone or use the internet.