Critics, however, are focused on the period after the Sept. 11, 2001, attacks, when Ms. Haspel ran a secret “black site” C.I.A. prison in Thailand where detainees were subjected to brutal interrogation techniques. She was also involved in approving the destruction of videotapes of interrogation sessions at the Thailand prison. The agency has since closed such prisons and renounced the techniques, including waterboarding, sleep deprivation and confinement in boxes.

Among the materials handed over to the Senate are logs of internal chats from a C.I.A. instant messaging system in which Ms. Haspel appeared to raise no objections to the interrogation program or the methods employed against Qaeda suspects, according to an American official, who like others declined to be identified discussing confidential matters.

The official said Ms. Haspel seemed completely comfortable with what was being done to the prisoners. Her allies said she hardly relished the task but was carrying out a program approved by policymakers and lawyers.

Although the Senate has had the chat logs for some time, the White House appeared to learn of them only late last week. Meeting with Ms. Haspel at the White House on Friday, some officials appeared unsatisfied with how she planned to address questions about the interrogation program and the destruction of videotapes, according to current and former officials.

The officials asked pointed questions and appeared skeptical that Ms. Haspel would be able to rebut critics on the Intelligence Committee. Ms. Haspel left the meetings concerned that the administration might not vigorously defend her and that the C.I.A. as a whole was at risk of being abandoned by a president who has previously excoriated the nation’s intelligence agencies.

She was acutely aware of what happened to Dr. Ronny L. Jackson, the White House physician who withdrew his nomination for secretary of veterans affairs amid allegations about his workplace conduct, the current and former officials said.

Ms. Haspel did not want to be the next performer ushered onto the set of the Trump show, humiliated and then sent packing, they said. She agreed to the nomination out a sense of loyalty to the institution, they added, but would be just as happy to step back into her role as deputy.