A terror suspect who was once found with a map marked with the flightpath to Birmingham International Airport has defeated the UK Government's bid to deport him to Libya.
The man, who can only be identified by the initials DD, has been described by a court as "real and direct threat to the national security of the UK".
A second Libyan, known only as AS and described as a "committed Islamist extremist" also won his appeal against deportation.
AS was also ruled to be a "clear danger to national security". A Special Immigration Appeals Commission (Siac) document said: "He is an Islamic extremist who has engaged actively and as a senior member with a terrorist group clearly engaged in support work for jihadist activities."
AS was involved with a "serious terrorist group" based in Milan which was monitored by the Italian authorities.
The terror cell was probably about to go into the operational stage of a terror attack, most likely inside Europe, it said.
The terrorists referred to a "football game" as a coded metaphor for their terror plot, the document said. In September 2002, one member of the group was recorded saying: "The game is ready ... We will win, always victorious. There is no defeat. We too have to depart if God so wills."
The Siac document said AS paid £2,000 to be smuggled from Malta to Britain in February 2002. He claimed asylum in April of that year.
The following month he was arrested under immigration powers and later prosecuted for two offences relating to forged and stolen travel documents, which he admitted.
After serving concurrent prison sentences of one and two months, he was returned to immigration detention. Italy made an extradition request for AS which was later withdrawn.
The court ruled that DD was a "global jihadist with links to the Taliban and al Qaida".
DD and AS have been on bail since, and are now believed to have been put under a control order. They are likely to face a curfew and other restrictions on their activities.
It emerged in Siac documents last year that an A-Z street atlas was found in the boot of a car at DD's home, showing markings along footpaths which ran under aircraft routes to Birmingham airport, Britain's sixth largest.
"The markings might have been for reconnaissance purposes but might have a wholly innocent explanation," said Siac last year. The Home Secretary's case also claimed DD's brother-in-law Serhane Fakhet blew himself up in a raid by Spanish police in the wake of the 2003 Madrid train bombings.
Another brother-in-law of DD, Mustapha Maymouni, is serving 18 years in Morocco for his part in the Casablanca bombings which killed 45 people in May 2003.
Fakhet, alias "The Tunisian", was the suspected ringleader of the cell which carried out the Madrid bombings, killing 191. He died in an explosion in a Madrid suburb in April 2004, which also killed a policeman and injured 11 others.
Siac ruled that DD, who was born in 1975, is a member of the Libyan Islamic Fighting Group (LIFG), which seeks to replace the Gadaffi regime with a hard-line Islamic state. The organisation is banned in the UK.
DD has used a number of aliases including Mullah Shakir Ghaznawi, Imad Al Libi, Hossein Abselam and Abdullah Bataebeid.