President Donald Trump, Attorney General Jeff Sessions, center and FBI Director Christopher Wray, right, sit together at the FBI National Academy graduation ceremony, Friday, Dec. 15, 2017, in Quantico, Va. The White House says newly revealed FBI records show there is "extreme bias" against President Donald Trump among senior leadership at the FBI. The accusation came hours before Trump was scheduled to speak Friday at the FBI training academy. (AP Photo/Evan Vucci)
President Donald Trump, Attorney General Jeff Sessions, center and FBI Director Christopher Wray, right, sit together at the FBI National Academy graduation ceremony, Friday, Dec. 15, 2017, in Quantico, Va. The White House says newly revealed FBI records show there is "extreme bias" against President Donald Trump among senior leadership at the FBI. The accusation came hours before Trump was scheduled to speak Friday at the FBI training academy. (AP Photo/Evan Vucci) Credit: Evan Vucci

QUANTICO, Va. — Taking aim at the credibility of the FBI, President Donald Trump unleashed a blistering attack on the bureau’s leadership even as he praised state and local police officers as a bulwark against rising violence and crime.

Trump denounced the bureau for its handling of the Hillary Clinton email investigation, calling it “really disgraceful” and continuing his questioning of his country’s intelligence and law enforcement institutions as no president before.

“It’s a shame what’s happened with the FBI,” the president said. “We’re going to rebuild the FBI, it’ll be bigger and better than ever, but it is very sad when you look at those documents, and how they’ve done that is really, really disgraceful, and you have a lot of very angry people that are seeing it.”

The president’s broadside appeared to reflect his anger over revelations that senior FBI officials exchanged anti-Trump and pro-Hillary Clinton text messages while working on last year’s Clinton probe and during special counsel Robert Mueller’s investigation into whether Trump associates colluded with Russian officials in the 2016 election.

Trump laced into the bureau as he was departing for its training academy in Virginia, where he lavished praise on graduates of a weeks-long FBI National Academy program for law enforcement leaders from around the country.

Trump depicted a nation besieged by violence, using dark rhetoric that was a stark departure from the language of his predecessors. He evoked this week’s attempted terror attack in New York when he called for stricter immigration policies. He also delivered a stern warning to members of the international gang MS-13 that his administration will root them out and arrest them.

Violent crime has increased nationally the last two years but has dropped precipitously over the last quarter century. Gun violence in Chicago has dropped in 2017 from 2016 and of Dec. 10 there had been 620 homicides compared to 730 at the same time last year.

Edits to the Comey draft appeared to soften the gravity of the bureau’s finding in its 2016 investigation of Hillary Clinton’s use of a private email server while secretary of state.

“It is very sad when you look at those documents, how they’ve done that is really, really disgraceful, and you have a lot of really angry people who are seeing it,” Trump said of the document.

With the attack, the White House joined a growing movement among the conservative media and some Republicans to question the integrity of Mueller’s investigation.