INDIANAPOLIS (AP) - A federal judge ruled Friday that an American convicted of fighting alongside the Taliban must be allowed to pray daily in a group with other Muslim inmates at his high-security prison in Indiana.

Barring John Walker Lindh and his fellow Muslims from engaging in daily group ritual prayer violates a 1993 law that bans the government from curtailing religious speech without showing a compelling interest, U.S. District Judge Jane Magnus-Stinson ruled.

The judge blocked the prison from enforcing its ban on daily group prayer, but she noted that her ruling does not prohibit the prison from taking less restrictive security measures.

Group prayers had been allowed once a week and on high holy days such as Ramadan or Christmas in the prison's Communications Management Unit in Terre Haute, Ind. But at other times, inmates had to pray alone in their cells.

Lindh said that didn't meet the Quran's requirements, and that the Hanbali school of Islam to which he adheres requires him to pray daily with other Muslims. Lawyers for the American Civil Liberties Union of Indiana, which represented Lindh, argued that prayer was restricted even though games and some other group activities were not.

Prison officials argued that the same restrictions applied to inmates of all religions. They also argued that it would be dangerous, unaffordable and unfair to other inmates to meet Lindh's demands. Government witnesses testified that Muslims, who make up the majority of inmates in the unit, have operated like a gang under the guise of religious activity.

U.S. Attorney Joe Hogsett, whose office represented the prison, said Friday that prosecutors were considering their next step, including a possible appeal.

"This case deals with critically important issues that have significance both inside and outside the walls of our federal prison facilities," Hogsett said. "Our concern continues to be the safety and security of both our federal prison system and the United States of America."

Ken Falk, legal director of the ACLU of Indiana, noted Friday that witnesses testified prisoners were allowed for many years to pray daily while they were out of their cells, both in the multi-purpose room and throughout the prison "and it never caused any problem."

"To now argue that this somehow going to be a major security problem was incorrect," Falk said.