Former special counsel Robert Mueller affirmed that a president can be charged with crimes after leaving office.

During his testimony in front of the House Judiciary Committee, he said Justice Department guidelines prevented him from considering charges against President Donald Trump while he is in office.

"Could you charge the president with a crime after he left office?" Rep. Ken Buck (R-Colo.) asked during Mueller's testimony. 

"Yes," he replied. 

Buck seemed surprised by the former special counsel's answer, and asked the question again. 

RELATED: Watch Live: Russia probe special counsel Robert Mueller testifies before Congress

RELATED: Trump uses Twitter to weigh in during Mueller's testimony

Because of the longtime Justice Department guidance that a sitting president cannot be indicted, Mueller said "one of the tools a prosecutor would use is not there."

Mueller has said his investigators could not exonerate Trump on obstruction of justice. His report said they did not find sufficient evidence to establish charges of criminal conspiracy between the Trump campaign and Russia.

Mueller is testifying Wednesday before the House Judiciary Committee about his Russia investigation.

President Trump's sons and advisers weighed in on the hearing on Twitter. Donald Trump Jr. called the hearing a "disaster" for Democrats. 

Trump himself has not weighed in on the hearing, but tweeted several times quoting Fox News journalists. 

“This has been a disaster for the Democrats and a disaster for the reputation of Robert Mueller," he wrote in a tweet, quoting Fox News anchor Chris Wallace