A federal appeals court has ruled that certain records from the prosecution of Keonna Thomas, a North Philadelphia woman sentenced to eight years in prison for aiding the Islamic State online, must remain sealed to avoid risks to national security.

A three-judge panel of the U.S. Court of Appeals for the Third Circuit on Friday upheld a ruling by U.S. District Judge Michael Baylson of the Eastern District of Pennsylvania that denied self-described “alternative news source” The Philly Declaration’s motion to unseal Thomas’ guilty plea document. The court vacated Baylson’s order denying The Declaration’s request to access a sealed grand jury exhibit, instead sending it back to him to determine whether portions of it can be redacted and released.