FILE PHOTO: Ahmed Khalfan Ghailani, the first Guantanamo detainee to have faced a U.S. civilian trial, is pictured in this undated FBI photograph obtained June 9, 2009. FBI/Handout via REUTERS/File Photo

(Reuters) - A federal appeals court on Wednesday revived a lawsuit in which Ahmed Khalfan Ghailani, a former Guantanamo Bay detainee convicted over the 1998 bombings of U.S. embassies in Kenya and Tanzania, said prison officials violated his right to participate in group prayer.

The 10th U.S. Circuit Court of Appeals in Denver said a lower court judge erred in dismissing Ghailani’s lawsuit over being forbidden to pray Jumu‘ah, a Muslim prayer held on Fridays, at the Florence, Colorado, Supermax prison where he is serving a life sentence without parole.

Ghailani, 43, a Tanzanian native and former al-Qaeda operative, was the first former detainee at the Guantanamo Bay, Cuba, military prison to be tried in a U.S. civilian court.

A Manhattan federal jury convicted him in 2010 of conspiring to damage or destroy government property in connection with the Aug. 7, 1998 bombings, which killed 224 people.

Ghailani had challenged the legality of the prayer ban and other “special administrative measures” (SAMs) imposed on him because of his past ties to terrorism and terrorist groups.

In Wednesday’s decision, Circuit Judge Stephanie Seymour said the ban did not violate Ghailani’s right to freely exercise his religion under the Constitution’s First Amendment.

But she said Ghailani could try to show that the ban violated the Religious Freedom Restoration Act of 1993, which has a different standard of proof.

Ghailani “need not plead facts showing that the actions of which he complains were not reasonably related to legitimate penological interests,” or did not advance and were not the least restrictive means of furthering a compelling governmental interest, Seymour wrote.

The appeals court also dismissed as moot Ghailani’s claims over other SAMs that the government allowed to expire in June 2015. It returned the case to U.S. District Judge Christine Arguello in Denver.

Sean Connelly, who argued Ghailani’s appeal in November, in an email said he was pleased the decision requires the government to justify denying Ghailani’s “right to engage in the group prayer required by his religion.”

A spokeswoman for the Department of Justice declined to comment.

In a handwritten brief, Ghailani had said prison officials imposed the SAMs based on “speculation” he might “commit an act of terror” while in prison.

He called this a type of “post-hoc rationalization” that Congress tried to prevent when passing the RFRA.

The appeals court panel originally included Neil Gorsuch, who became a U.S. Supreme Court justice in April. He did not participate in Wednesday’s 2-0 decision.