MADRID, Spain (CNN) -- A Moroccan court sentenced a Moroccan man to 20 years in prison for his role in the Madrid train bombings of 2004, in a case built on evidence from Spanish police, a Spanish court spokeswoman said Friday.
Abdelilah Hriz (left) is escorted to the anti-terrorist court in Sale, near the Moroccan capital, Rabat.
The sentence against Abdelilah Hriz was announced late Thursday.
Hriz, in his early 30s, was arrested in Morocco last January on a Spanish warrant for participation in the attacks that killed 191 people and wounded more than 1,800 on Madrid commuter trains.
He was convicted of "constituting a criminal group to carry out a terrorist act" and "complicity in the destruction of transport systems" and "participating in the premeditated assault," said the spokeswoman for Spain's National Court in Madrid.
Morocco and Spain do not have an extradition treaty and it is believed to be a rare instance in which Morocco tried one of its nationals for a crime committed abroad, said the spokeswoman, who by custom is not identified.
The main trial of the train bombing defendants was held in 2007 at the National Court in Madrid, resulting in numerous convictions.
Spain's Supreme Court last summer ruled on appeals, which left a total of 18 convictions, including 14 Islamic militants and four Spaniards, the latter for trafficking in explosives used in the attacks.
But Spanish authorities have long said that a few suspects remained at large, and Hriz was one of them.
Spain has sought Hriz since 2005, after DNA tests indicated he had been present at a rural home near Madrid where authorities say the bombs were assembled, and at a suburban Madrid apartment where seven suspected terrorists blew themselves up, three weeks after the attacks as police closed in on their hideout.
Spanish news reports said Hriz admitted that he had been in Spain from October 2003 to March 2004 but that he denied the charges against him in court in Sale, Morocco, near the capital, Rabat.
The Moroccan prosecution sought life in prison against Hriz, Spanish media reported, but the court decided on a sentence of 20 years.
Spain's National Court expressed "satisfaction" at Morocco's "complete collaboration" in the case, the spokeswoman said. The cooperation included a visit to Morocco by Spain's main investigating magistrate for the train bombings.