A former Stanford University student who sued the government over her placement on a U.S. government no-fly list is not a threat to national security and was the victim of a bureaucratic "mistake," a federal judge ruled today.

The decision (.pdf) makes Rahinah Ibrahim, 48, the first person to successfully challenge placement on a government watch list.

Ibrahim’s saga began in 2005 when she was a visiting doctoral student in architecture and design from Malaysia. On her way to Kona, Hawaii to present a paper on affordable housing, Ibrahim was told she was on a watch list, detained, handcuffed and questioned for two hours at San Francisco International Airport.

The month before, the FBI had visited the woman at her Stanford apartment, inquiring whether she had any connections to the Malaysian terror group Jemaah Islamiyah, according to the woman’s videotaped deposition played in open court.

U.S. District Judge William Alsup ordered the government to either purge her name from the list, or certify that it has already been removed. Federal watch lists contain some 875,000 names. (The judge is set to unseal a larger judicial order that discloses whether the woman is indeed currently on a watch list. However, he gave the government until April 15 to ask a federal appeals court to bar its publication.)

Ibrahim was not seeking monetary damages. She wanted to clear her name, her attorney, Elizabeth Marie Pipkin said in court last month.

Pipkin and a team of lawyers handled the case pro bono, spending $300,000 in court costs and racking up $3.8 million in legal fees covering some 11,000 hours of work, she said. "Why in the United States of America does it cost that much to clear a woman's name?" she asked in a telephone interview.

The woman, who is now a professor in Malaysia, eventually was allowed to leave the United States but has been denied a return visit, even to her own civil trial.

The trial last month was shrouded in extraordinary secrecy, with closed court hearings and non-public classified exhibits. Judge Alsup today issued his full judgement under seal, but made public an abbreviated version that we're allowed to know about.