WASHINGTON — When the House select committee investigating the 2012 attacks on American government outposts in Benghazi, Libya, was created, Democrats immediately criticized it as a partisan effort to damage the political fortunes of Hillary Rodham Clinton.

But Representative Trey Gowdy, the South Carolina Republican and former federal prosecutor who is the committee’s chairman, told Fox News at the time: “I have no friends to reward and no foes to punish. We’re going to go wherever the facts take us.”

Now, 17 months later — longer than the Watergate investigation lasted — interviews with current and former committee staff members as well as internal committee documents reviewed by The New York Times show the extent to which the focus of the committee’s work has shifted from the circumstances surrounding the Benghazi attack to the politically charged issue of Mrs. Clinton’s use of a private email server while she was secretary of state.

A committee with a stated initial goal of learning more about how four Americans, including Ambassador J. Christopher Stevens, were killed in Libya has created a political whirlwind in Washington, affecting not only Mrs. Clinton’s presidential campaign, but now also the race for House speaker. Mrs. Clinton is scheduled to testify in front of the committee on Oct. 22.