At the end of January, Mary B. McCord had a ringside seat to history.

It was she, as a career attorney overseeing the high-profile Justice Department probe into potential collusion between associates of President Trump and the Kremlin, who accompanied the acting attorney general, Sally Yates, to the White House to warn the president’s lawyer that the national security adviser was at risk of being blackmailed, according to an individual familiar with the matter.

Yates said she thought “it was important” to bring a career national security professional. After all, McCord “had been the one who was most intimately familiar” with the facts, said Yates, who did not name the attorney in congressional testimony. Nor would McCord in an interview confirm or comment on the visit.

McCord, who spent the past seven months as acting head of the Justice Department’s National Security Division, two weeks ago returned to her former job as principal deputy assistant attorney general. And on Friday, she is resigning after more than two decades with the Justice Department to work in academia.

McCord, who said she was not interested in staying on as a political appointee, said she’s confident that the wide-ranging Russia probe, which began last July, will be in good hands with the career attorneys and the FBI special agents who have deep experience in counterintelligence work.

As head of the National Security Division, McCord oversaw a variety of investigations ranging from the potential Trump-Russian ties to counter terrorism, cyber and export control crimes. (Michael S. Williamson/The Washington Post)

McCord also had no comment on President Trump’s firing this week of FBI Director James B. Comey.

She said, however, that she was not leaving out of frustration or incompatibility with the current administration. “If I waited for a particular investigation to finish, there would absolutely never be a time to leave,” she said.

McCord would not comment on the Russia investigation, but she said it was important for the government to publicize the fact that Russia had interfered in the 2016 election. “There’s value to calling out: We know what you’re doing,” she said. “We know why you’re doing it.”

That sort of transparency is key to inoculating the public against efforts to undermine the democratic process, she said. “Hopefully the voters, whether they’re here, or in France, or in Germany, wherever Russia tries to meddle, will understand that,” she said.

McCord took over as acting assistant attorney general for national security when John Carlin left the department in October to take a job in the private sector.

“Mary is a really good lawyer,” said Carlin, who recruited McCord into the NSD in 2014 from the U.S. attorney’s office in the District of Columbia. “She was an appellate specialist and has an incredible devotion to law, and genuinely loves learning and tackling hard legal issues throughout her career.”

One of McCord’s enduring memories dates to September 2012, when the Islamic militant group Ansar al-Sharia attacked U.S. compounds in Benghazi, Libya. U.S. Ambassador J. Christopher Stevens and three other Americans died in the assault. Then-Attorney General Eric H. Holder Jr. immediately assigned the case to her office, and she was on the phone briefing him the weekend after it happened on what investigators had learned in the first three days.

The national security team at her office, counterterrorism prosecutors at the NSD, and FBI agents in New York worked together to investigate the attack. In August 2013, prosecutors filed charges against the group’s leader, Ahmed Abu Khattala. In June 2014, as McCord was moving to the national security division, the FBI, Special Operations forces and the Justice Department were planning a capture operation. “I was with the attorney general when the [senior officials] decided to go for it,” she recalled. “That night it was set to happen, I remember all night, just waiting for word — because the worst thing that could have happened in my mind was to lose an American life.

“When we heard in real time it was successful and no one was hurt,” there was elation, she said.

Abu Khattala is set to stand trial in September in U.S. District Court in Washington. Though she will no longer be with the department, McCord is “hopeful that we’ll bring him to justice and he’ll never see the light of day.” She added, “I feel very confident we’ll convict him.”

McCord’s work ethic is legend. “We used to beg her to take care of herself,” recalled Carlin. “She nearly lost vision in one eye because she needed to get it treated” and delayed doing so because she was working so hard, reading legal briefs. She eventually got surgery to repair a detached retina. She also regularly took conference calls in parking lots after shuttling her teenagers to weekend travel soccer games.

She credits her husband, Sheldon “Shelly” Snook, with carrying the load. He’s also a lawyer and a former longtime administrative assistant for the U.S. District Court. He is now special assistant to the counselor for the chief justice of the U.S. Supreme Court.

“There are days I go home frustrated or in a horrible mood, and he’s born the brunt of that,” she said. “Not once has he complained.”

Kenneth Wainstein, the first NSD head, who made McCord his deputy chief in the sex offense and domestic violence section when he was the U.S. attorney for the District of Columbia, said McCord was always “a standout prosecutor.”

While at the helm of the NSD, she oversaw the indictments of four alleged Russian hackers who plundered Yahoo email accounts, and the guilty plea by ZTE Corp., a major Chinese state-owned telecom, for selling equipment containing items of U.S. origin to Iran in violation of sanctions. ZTE’s total settlement, with the Commerce, Treasury and Justice departments, neared $1 billion and included the largest criminal fine for a sanctions violation case.

But, after 25 years in government, she’s ready to move on.

“For me, it’s a natural time now to get back to what I really like to spend time doing.” That means “digging deep” into legal issues and being with her husband and three children. Her next career move, she said, will afford her time to do both.