Can the government censor you for tweeting happy birthday to a judge? The Senate Judiciary Committee recently voted 21–0 to advance a bill that would allow exactly that. If it is enacted, every American could face mandatory take-down orders for posting basic facts online about federal judges, including birth dates, spouses’ jobs and the colleges attended by their children. Because the bill stifles access to relevant information about public officials and arbitrarily limits its restrictions to the internet but not other media, it would violate the First Amendment.

The impetus for the proposed legislation was a tragic event: the murder last year of Daniel Anderl, son of Judge Esther Salas, at their home. Here’s how the Daniel Anderl Judicial Security and Privacy Act would work. If you post “covered information” about a federal judge online, that judge (or a designated federal official) can send you a written request to take it down. If you don’t comply within 72 hours, the judge can sue you. If you lose, you have to take down the information and pay the judge’s legal fees and court costs.

The bill’s “covered information” includes facts often found in public directories, like the judge’s home phone number and address. It includes biographical details such as “full date of birth,” identification of minor children, and any school or employer of immediate family. The bill would thus allow significant government censorship of truthful speech about federal judges.

The Supreme Court has repeatedly struck down laws that prohibit the publication of sensitive but true personal information. In Smith v. Daily Mail (1979), the court explained that “state action to punish the publication of truthful information seldom can satisfy constitutional standards.” In Florida Star v. B.J.F. (1989), the court held that punishments for publishing lawfully obtained truthful information may be imposed “only when narrowly tailored to a state interest of the highest order.”

To escape the force of these precedents, the bill provides an exception for covered information that “is relevant to and displayed as part of a news story, commentary, editorial, or other speech on a matter of public concern.” Because the Supreme Court’s precedents dealt with “truthful information about a matter of public significance,” defenders of the bill argue that this exception saves its constitutionality. It doesn’t.

Federal judges are public figures. Truthful information about them can facilitate speech on matters of public concern, even when that truthful information is not itself posted as part of a commentary or news story. The Wall Street Journal recently published an investigative report revealing dozens of judicial conflict-of-interest violations. The investigation looked at the stock held not only by judges, but also by their spouses and minor children. If online encyclopedias and databases were no longer allowed to publish the employers of a judge’s family or even the names of a judge’s children, such investigations would be seriously hampered.

Loss of access to truthful information about public officials can mean loss of the ability to produce news and commentary. The bill’s limited exception for information “relevant to and displayed as part of” a news or commentary article doesn’t sufficiently address that fundamental problem.

Nor is the bill “narrowly tailored.” It applies only to information published on the internet, not in print, television or radio. That underinclusiveness is fatal. As the justices wrote in Florida Star, “when a State attempts the extraordinary measure of punishing truthful publication in the name of privacy, it must demonstrate its commitment to advancing this interest by applying its prohibition evenhandedly, to the smalltime disseminator as well as the media giant.”

Applying this principle, a federal court in 2017 preliminarily enjoined a California privacy law that similarly limited its restrictions to the internet. Remarkably, Sens. Tom Cotton (R., Ark.), Ted Cruz (R., Texas), and Alex Padilla (D., Calif.) at the committee hearing for the federal bill praised it as explicitly modeled on California’s law, without even mentioning that adverse decision.

If passed, a federal “judicial privacy” law would likely suffer the same fate as the many similar state laws that have been struck down by the courts. Securing the safety of the federal judiciary is a worthy goal, but it’s one that can be achieved without banning truthful speech.