Michael V. Hayden, a principal at the Chertoff Group and visiting professor at George Mason University’s Schar School of Policy and Government, was director of the National Security Agency from 1999 to 2005 and the Central Intelligence Agency from 2006 to 2009.

President Trump’s executive order on immigration was ill-conceived, poorly implemented and ill-explained. To be fair, it would have been hard to explain since it was not the product of intelligence and security professionals demanding change, but rather policy, political and ideological personalities close to the president fulfilling a campaign promise to deal with a threat they had overhyped.

I’ve heard from a lot of intelligence professionals who are going to have to live with the consequences. They noted that six of the seven countries involved in the ban (Iran being somewhat an exception) are troubled, fragmented states where human sources are essential to defeating threats to the United States.

Paradoxically, they pointed out how the executive order breached faith with those very sources, many of whom they had promised to always protect with the full might of our government and our people. Sources who had risked much, if not all, to keep Americans safe.

I understood their angst. As CIA director, I reminded them at their case officer graduations that, when they recruited a source, they would likely be the only face of America that the source would see. And that in the act of recruitment they would assume a powerful and permanent moral responsibility for the well-being of the source and his or her loved ones.

(Jayne Orenstein,Dalton Bennett,Natalie Jennings/The Washington Post)

The case officers believed that they were also empowered to offer the full faith and credit of the American nation for that task. Now, they told me, that promise was eroding.

Some will quibble that this, at least technically, is not really the case. That this is a temporary ban (maybe) and exceptions can be made (possibly). But as a former station chief told me, in the places where intelligence officers operate, rumor, whisper and conspiratorial chatter rule people’s lives. It doesn’t take paranoia to connect the action of the executive order with the hateful, anti-Islamic language of the campaign. In the Middle East, with its honor-based cultures, it’s easier to recruit someone we have been shooting at than it is to recruit someone whose society has been insulted.

As the station chief reminded me, the fundamental posture of an intelligence service looking for sources is that “We welcome you, you have value. Our society respects you. More than your own.” He feared that would no longer be the powerful American message it once was.

The simple idea of America didn’t hurt either. The station chief said that one of the fundamentals of his business was selling the dream. The Soviets “had a hard time with that. We had it easy. A lot of intelligence targets — officials, military figures, African revolutionaries, tribal leaders — railed against our policies, our interventions, many things . . . but they loved America. It was the idea of the country as a special place. They didn’t necessarily want to go there, but it was a place they kept in their minds where they would be welcome.”

The station chief and I knew Mohammed Shahwani, an Iraqi and American hero. Shawani carried the Iraqi flag at the 1960 Rome Olympics and later became a war hero as a commander of a special forces unit in the war against Iran. His popularity grew to a point where Saddam Hussein viewed him as a threat and he had to flee for his life.

Shahwani settled in Leesburg, Va., from where the United States convinced him after the invasion of Iraq to return to set up and run Iraq’s post-Hussein intelligence service. A Sunni, he established a nonsectarian service that was a trusted, professional partner to the CIA and U.S. forces. Not sectarian enough for Shiite Prime Minister Nouri al-Maliki, Shahwani was eventually sacked as U.S. influence waned.

Shahwani acted because he was an Iraqi patriot, but also because he was welcomed and sheltered by the United States, and believed he would be again.

Of course, today any members of Shahwani’s family still in Iraq are forbidden to enter the United States.

My station chief asks, “How would you look him in the eye these days and promise him we’d take care of him and the men who follow him? What do you tell him to tell those men? We’ll take care of them no matter what? That our president is shoulder to shoulder with them?”

Great questions, since we are at war in Iraq today and desperately need partners of Shahwani’s character.

These effects will not pass quickly. These are not short-term, transactional societies. Insults rarely just fade away. Honor patiently waits to be satisfied. In the meantime, we will be left with the weak and the merely avaricious, agents who will cut a deal just for the money, the worst kind of sources.

To all the tough-guy ideological thinkers who created this, professional CIA case officers will do what they can to deal with the unnecessary burden you have given them.

But in the future you might want to consult them — before you rush proclamations out the door.