For officials in the Trump administration, leaving the government and writing a book has become a reliable and lucrative exit strategy — so much so that it has created a small army of literary agents who specialize in snapping up the next tell-all memoir. For anyone with name recognition in D.C., it has perhaps never been easier to scoop up a sizable advance and make the best-seller list.

But for rank-and-file members of the intelligence community, the process is not so easy. Employees who formerly had access to sensitive information must submit manuscripts for a government “pre-publication review,” intended to ensure that they don’t divulge official secrets.

The result has been a massive system that processes thousands of submissions, in which the rules are broad and vague, and vary from one agency to another. The process can drag on for months or, in some cases, years, and can force authors to choose between deleting text or publishing pages of type blacked out by U.S. government censors.

But the American Civil Liberties Union and Knight First Amendment Institute at Columbia University are challenging this redaction regime. In a lawsuit filed on Tuesday, the groups allege that pre-publication review amounts to a “far-reaching system of prior restraint,” and that the government’s arbitrary and sometimes confounding censorship decisions are unconstitutional under the First Amendment.

“This far-reaching censorship system simply can’t be squared with the Constitution,” Jameel Jaffer, executive director of the Knight First Amendment Institute, said in a statement. “The government has a legitimate interest in protecting bona fide national security secrets, but this system sweeps too broadly, fails to limit the discretion of government censors, and suppresses political speech that is vital to informing public debate.”

The lawsuit has five plaintiffs, all of whom are former members of the military or intelligence community. They allege that the delays and censorship involved in prepublication review have unfairly damaged their work as academics, authors, and outside experts, and are asking the court to stop the government from enforcing their review agreements.

“To survive First Amendment scrutiny, a requirement of prepublication review would have to, at a minimum, apply only to those entrusted with the most closely held government secrets; apply only to material reasonably likely to contain those secrets; provide clear notice of what must be submitted and what standards will be applied; tightly cabin the discretion of government censors; include strict and definite time limits for completion of review; require censors to explain their decisions; and assure that those decisions are subject to prompt review by the courts,” the complaint reads. “The prepublication review system, in its current form, has none of these features.”

Some government agencies, like the CIA, have since their founding made employees sign comprehensive nondisclosure agreements. But the use of prepublication agreements exploded in the 1980s, when President Ronald Reagan issued a National Security Directive requiring that anyone with access to what’s known as “sensitive compartmented information” sign a nondisclosure agreement that made them subject to future prepublication review.

Some of the most important first-person accounts of the war on terror have been censored this way. In 2011, a former FBI agent named Ali Soufan published a memoir called “The Black Banners: The Inside Story of 9/11 and the War against Al-Qaeda,” which detailed how, in the aftermath of the 9/11 attacks, the CIA sidelined experienced interrogators like Soufan in favor of what they called “enhanced interrogation.” Black marks obscure many passages in the book.

By contrast, books defending the government’s actions seem to get a pass. For example, the memoir of Jose Rodriguez Jr., the former head of the CIA’s clandestine service, titled “Hard Measures: How Aggressive CIA Actions After 9/11 Saved American Lives,” was published with far less scrutiny, according to the Washington Post.

A separate Freedom of Information lawsuit by the ACLU and the Knight Institute has also uncovered evidence of senior government officials getting their books fast-tracked. In response, the government provided documents showing that it took just seven weeks for Hillary Clinton’s memoir to be reviewed, and eight weeks for former FBI Director James Comey’s. Email exchanges released under the FOIA also showed that reviewers faced pressure from higher-ups to turn those manuscripts around quickly. By contrast, the average book-length manuscript takes the CIA a year to review, according to a draft inspector general’s report unearthed by the same lawsuit.