WASHINGTON — John Sullivan , the deputy secretary of state, said on Wednesday that President Trump’s personal lawyer Rudolph W. Giuliani was involved in a smear campaign to oust the ambassador to Ukraine, publicly confirming a key part of the saga behind the impeachment inquiry.

Jumping into an impeachment fight that so far has been waged in the House behind closed doors, Senate Democrats used Mr. Sullivan’s nomination to be President Trump’s next ambassador to Russia to bring the drama into the open. Mr. Sullivan, testifying under oath and on camera before the Senate Foreign Relations Committee, corroborated private testimony from one of House Democrats’ central impeachment witnesses, Marie L. Yovanovitch, the former ambassador to Ukraine.

Pressed on whether he believed it was appropriate for the president to demand investigations into domestic political opponents, Mr. Sullivan said, “I don’t think that would be in accord with our values.”

How and why Ms. Yovanovitch , the former envoy to Ukraine and a longtime diplomat, was recalled from her job has become a question at the heart at the impeachment investigation into whether Mr. Trump enlisted a foreign government to target his political opponents. While Mr. Sullivan did not reveal significant new information, he testified on camera, and became the highest ranking official to publicly affirm that Ms. Yovanovitch had served “admirably and capably.” He also went on the record with his belief that Mr. Giuliani helped to coordinate an effort to denigrate her.