Rex Tillerson, whom Trump fired via Twitter last month.

“I’ll do my part to end the vacancies,”

Pompeo said. He vowed to foster a State Department culture that “finds its swagger once again. We will be effective, expeditionary, diverse, and successful in fulfilling our mission.”

The West Point graduate and Gulf War veteran pushed backon criticismthat he is a hard-liner. No one “understands the value of diplomacy and the terror and tragedy that is war like someone who has served in uniform,” he said. “It’s the last resort. It must always be so.”

Pompeo, a critic of the 2015 nuclear disarmament accord with Iran, acknowledged that Iran is complying with terms of the deal. But he went back and forth whether he would seek to fix what he called “its egregious flaws,” or withdraw and then try to renegotiate it — even though European allies and Iran have rejected that possibility.

Trump has vowed to withdraw from the deal next month unless it is revised.

Pompeo vowed to toughen U.S. sanctions that have targeted Russian President Vladimir Putin’s inner circle and other senior government officials. Moscow “continues to act aggressively, enabled by years of soft policy toward that aggression. That’s now over,” Pompeo said. Russia, he added, “has not gotten the message.”

If confirmed, Pompeo will also help plan a proposed high-stakes nuclear summit between Trump and North Korean leader Kim Jong Un, a task he was already immersed in as CIA director.

“No one is under any illusions” that a summit will produce a comprehensive agreement to strip North Korea of its nuclear weapons, Pompeo said. But it could “set us down the course to achieve a diplomatic outcome that America and the world so desperately need.”

Pressed by Sen. Ben Cardin of Maryland, Pompeo also denied that he had ever called for overthrowing the North Korean government.

“I have never advocated for regime change,” Pompeo said.

He also pledged to rebuild the U.S. diplomatic presence in Cuba, which has dropped to a skeleton staff. President Barack Obama sought to end a half-century of hostilities with Havana by re-establishing ties in 2015, but Trump has reversed course and made it more difficult for travel and business.

Democrats used the hearing to criticize Trump’s erratic foreign policy, and urged Pompeo to push back when necessary.

“Will you enable President Trump’s worst instincts?” asked Sen. Bob Menendez of New Jersey, the ranking Democrat on the committee. “Will you stand up to [Trump] and say ‘No, you are wrong,’ or will you be a yes man?”

Pompeo said he would express his views forcefully but carry out the president’s policies once decisions were made. He said he shared Trump’s view that the 2015 Paris climate accord placed “an undue burden” on the United States, and that he supported Trump’s decision to withdraw from it.

He said he has been interviewed by special counsel Robert Mueller, who is investigating Russian interference in the 2016 election. He said he believed the Russians meddled in the campaign.

Sen. Cory Booker of New Jersey pressed Pompeo on past statements that critics called anti-Muslim, as well as his views on gay rights. Pompeo responded that he personally opposes same-sex marriage but that he respected equality in the workplace and would not tolerate discrimination against Muslims or gays.

One Republican on the Senate committee, Sen. Rand Paul of Kentucky, has said he will oppose Pompeo’s nomination because of his past defense of harsh CIA interrogation tactics that critics called torture.

Unless Pompeo gains the vote of at least one Democrat on the panel, his nomination probably would move to the full Senate “without recommendation.” He is likely to win confirmation there, but not without more debate.tracy.wilkinson@latimes.com