The FBI lies a lot.

Sometimes that's fully justified. Brave agents risk their lives to infiltrate terrorist cells, organized crime, and child-pornography rings. Subterfuge is vital to these operations, and needn't harm the country if done correctly. But there are certain kinds of lies and untruths that the FBI should carefully avoid. FBI Director James Comey isn't always able to identify them.

Consider his remarks on three separate subjects.

The first is the debate about whether Apple, Google, and other device manufacturers should build security vulnerabilities into their devices so that the tiny subset that police want to search can be compromised after a warrant is obtained. Comey went on 60 Minutes and misled its audience about whether a warrant is always needed to read your email. He "clarified" his remarks during a subsequent speech at the Brookings Institution. But key details of that speech turned out to be misleading too. Perhaps these were untruths spoken out of ignorance and lack of preparation rather than lies. Either way, an FBI director should take special care to speak accurately when engaged in public debate about important matters of public policy. Comey keeps failing that standard.

Subject No. 2 concerns an FBI lie that everyone acknowledges to be deliberate. Agents in Las Vegas suspected an illegal gambling ring was being run out of a few fancy hotel rooms. But they didn't have enough evidence for a search warrant. The law forbade them from entering unless the inhabitants let them in voluntarily.

The agents hatched a scheme. They would shut off the room's Internet connection as if it had broken, pose as hotel employees coming to fix the problem, and thereby gain the "consent" of the inhabitants to come in and look around. This is an affront to the Fourth Amendment and the concept of consent. The lawyer for the defendants capably articulates why Americans should object to the FBI's logic by sketching the society that we'd have if it was used more often:

The next time you call for assistance because the Internet service in your home is not working, the "technician" who comes to your door may actually be an undercover government agent. He will have secretly disconnected the service, knowing that you will naturally call for help and—when he shows up at your door, impersonating a technician—let him in. He will walk through each room of your home, claiming to diagnose the problem. Actually, he will be videotaping everything and everyone inside. He will have no reason to suspect you have broken the law, much less probable cause to obtain a search warrant. But that makes no difference, because by letting him in, you will have "consented" to an intensive search of your home.

The next time our telephone service goes out, the "repairman" who responds may actually be an FBI agent who cut the line himself. The next time your cable service goes fuzzy, your plumbing backs up, or your lights go dark, caveat emptor: the source of the problem may actually be the government agent lurking in his car down the street, waiting for you to call for help—thereby unknowingly "consenting" to him using a secret camera to record you and the most private spaces in your home.

Even if you think that the next service outrage in your home is real, so that an actual technician has responded, don't be too sure. Your consent is just as valid when the undercover agent lies to your face to falsely reassure you—even when he misleads you by holding realistic sounding telephone calls with made-up colleagues about what is actually a nonexistent problem. So, every time any technician or service provider comes to your door, you will feel the palpable dread that by opening it you are "consenting" to the government secretly spying on you and your family—with no basis whatever. Or at least that is inevitably the government's astonishing position before this Court, because those are the appalling facts of this case.

Imagine if every government agency, from the FBI to the IRS to the local police force to the municipal code department, adopted this approach and the courts went along. Yet after The New York Times flagged this case in an editorial about problematic lies told by the FBI, Comey defended it as "acting responsibly and legally."

He also defended another case mentioned in the same editorial, where the FBI posed as a journalistic organization. Comey himself recounts the gambit that was used:

In 2007, to solve a series of bomb threats and cyberattacks directed at a Seattle-area high school, an F.B.I. agent communicated online with the anonymous suspect. Relying on an agency behavioral assessment that the anonymous suspect was a narcissist, the online undercover officer portrayed himself as an employee of The Associated Press, and asked if the suspect would be willing to review a draft article about the threats and attacks, to be sure that the anonymous suspect was portrayed fairly.

The suspect agreed and clicked on a link relating to the draft “story,” which then deployed court-authorized tools to find him, and the case was solved. No actual story was published, and no one except the suspect interacted with the undercover “A.P.” employee or saw the fake draft story. Only the suspect was fooled, and it led to his arrest and the end of a frightening period for a high school.

That outcome is great—there's no reason to feel sorry for the perpetrator here. But of all the sorts of subterfuge that could've been used did they have to use journalism? Jack Shafer explains the problem:

What’s so special about journalists and journalism?

I hope my explanations don’t sound like special-interest pleading when I state that such acts corrupt the very existence of journalism. Whenever police officers masquerade as journalists, they introduce doubt into the public’s mind about whether the next person purporting to be a journalist is actually a police officer or the stories in the news are really bait set by police. It won’t take too many acts of imposture like the FBI’s in Seattle before the credibility of the press and the willingness of news sources to speak to reporters begins to fall, plugging the flow of information that nourishes a free society.

The FBI has institutional needs and a law-enforcement mission. But it ought not think so narrowly of its agenda, the consequences be damned. When FBI leaders participate in policy debates, they have a civic obligation to speak truthfully and accurately. Agents trying to catch bad guys have a legal obligation to respect the Fourth Amendment, and should refrain from bringing about a society with pervasive mistrust of anyone claiming to be a Wi-Fi repairman or an investigative journalist.

Given the FBI's long history of immoral and illegal conduct (it doesn't get much worse than urging Martin Luther King Jr. to commit suicide after threatening to expose his sex life to the public) you'd hope it would try to err on the side of caution. Comey claims that the FBI's use of deception "is subject to close oversight, both internally and by the courts that review our work." If so, the oversight isn't enough.

We want to hear what you think about this article. Submit a letter to the editor or write to letters@theatlantic.com.