Hillary Clinton has been first lady and secretary of state, but in between she served as a senator from New York for two terms. In Sunday's second presidential debate between Clinton and GOP nominee Donald Trump, Clinton's senate record came under fire. 

"I will tell you, she’s all talk. It doesn’t get done. All you have to do is take a look at her Senate run. Take a look at upstate New York," Trump said. "It turned out to be a disaster." 

Clinton served in the Senate from 2001 until 2009, putting her name on hundreds of pieces of legislation and serving on five Senate sub-committees, including the Committee on Budget, the Committee on Armed Services, the Committee on Environment and Public Works, the Committee on Health, Education, Labor and Pensions and a Special Committee on Aging. Does the Democratic presidential nominee's record warrant Trump's claim? 

Hillary Clinton Donald Trump went after Hillary Clinton's record in the second presidential debate, calling her two senate terms a "disaster." Photo: Getty Images

Trump has been relentless in his criticism of Clinton's Senate vote in favor of the Iraq war, which he insists he opposed despite evidence to the contrary. Clinton was, in fact, one of the 29 Democratic senators to vote for the invasion of Iraq in 2002. In total, 77 senators voted for the war while 23 opposed the resolution. Clinton has said she regrets the vote. She later opposed the Iraq War troop surge of 2007.

"I think that the decision to go to war in Iraq was a mistake," she told NBC's Matt Lauer last month. "And I have said that my voting to give President Bush that authority was, from my perspective, my mistake. I also believe that it is imperative that we learn from the mistakes, like after- action reports are supposed to do, and so we must learn what led us down that path so that it never happens again. I think I'm in the best possible position to be able to understand that and prevent it.

Another issue that came up in Sunday's debate, in regards to reforming the tax code, was the carried interest loophole, which allows money managers to collect their fees in the form of carried interest and pay the much lower capital gains tax instead of income tax. Clinton claimed she fought to get rid of the loophole in the Senate, but failed because of a Republican controlled-House and White House. Indeed, Clinton did push legislation to close the tax loophole and then-Sen. Barack Obama introduced legislation that would have ended the tax break — but Clinton was not vocal on the issue until she ran for president. 

One of the hallmarks of Clinton's Senate tenure, and one she touted in her debate performance Sunday, was her effort to help New York City recover and rebuild after the 9/11 terror attacks in 2001. Working with fellow New York Sen. Charles Schumer, she secured $21 billion in funding for the World Trade Center site's redevelopment. She also fought to secure health benefits for the first responders involved in the attacks. 

In the aftermath of 9/11, Clinton voted in favor of the USA Patriot Act, which granted the U.S. increased surveillance authority in the interest of preventing future terrorist attacks. Clinton expressed concerns about the law in 2005 before eventually voting to reauthorize it. She also opposed the Bush tax cuts — which lowered taxes for wealthier Americans — in 2001 and 2006. 

New York voters rewarded Clinton's first Senate term with a landslide reelection. As she claimed in the debate Sunday, Clinton won with a staggering 67 percent of the vote. She was able to turn the added credibility she gained as a senator into a competitive presidential run in 2008, where she was upset by eventual-President Obama, who named her Secretary of State in 2009. She served at the post until 2012.