Prosecutors in Mauritania have accused a jailed Canadian man of helping prepare an attack on an Algerian gas plant in January and have asked a court to extend his sentence to 10 years from two.

Aaron Yoon, 24, formerly of London, Ont., was convicted last July in Nouakchott on charges of having ties to a terrorist group and of posing a danger to national security. He has served almost half of his two-year sentence.

On Monday, prosecutors told a court that Yoon had acted in connivance with those responsible for the Jan. 16 attacks on an Algerian gas plant and the four-day siege that followed, killing more than 80 people. Yoon has denied involvement and protested that he is innocent.

"I came to Mauritania to study the Qur'an," he told the court on Monday, appearing briefly in a white traditional Mauritanian robe.

The court is expected to render its verdict on June 9 on whether Yoon must serve the longer sentence, The Associated Press reported Tuesday.

CBC News revealed earlier this month that Yoon had kept company with two Canadians from London in southwestern Ontario, and had travelled with them to Mauritania. The three had been students together at a high school in London.

Xristos Katsiroubas, 22, and Ali Medlej, about 24, are believed to have died fighting alongside the militants during the refinery attack.

Algerian forces stormed plant

The militants took control of the Tigantourine gas plant near Ein Amenas, Algeria, on Jan. 16. After a four-day hostage standoff, Algerian special forces stormed the facility.

A CBC News investigation learned that Medlej was briefly detained in Mauritania in the late fall of 2011, suspected of plotting an attack.

He was briefly questioned, held for 40 days and released without charges. Those who interrogated Medlej found him to have no ill intent and no malice, but they seem to have seriously misread the young Canadian’s objective, the CBC's Adrienne Arsenault reported.

Yoon was arrested in December 2011 for allegedly having ties to a terrorist group, and remained imprisoned in Nouakchott when his two friends would have departed for Mali.

Yoon — who has always maintained his innocence — got a two-year sentence in July 2012 after authorities suspected him of trying to visit militant training camps. His trial and sentencing happened before the Algeria attack, and before Mauritanian officials understood that Yoon was friends with Medlej and Katsiroubas.

It's that friendship that has now apparently led Mauritanian prosecutors to work to lengthen his sentence to 10 years.

With files from The Associated Press