But senior leaders at the Pentagon, speaking on the condition of anonymity, acknowledged that they were talking among themselves about what to do if Mr. Trump, who will still be president from Election Day to Inauguration Day, invokes the Insurrection Act and tries to send troops into the streets, as he repeatedly threatened to do during the protests against police brutality and systemic racism. Both General Milley and Defense Secretary Mark T. Esper opposed the move then, and Mr. Trump backed down…

Defense Department officials have privately discussed the possibility of Mr. Trump trying to use any civil unrest around the elections to put his thumb on the scales. Several Pentagon officials said that such a move could prompt resignations among many of Mr. Trump’s senior generals, starting at the top with General Milley.

The Air Force chief of staff, General Charles Q. Brown, the officials said, would also be unlikely to salute and carry out those orders. In the days after the killing of Mr. Floyd in police custody, General Brown released an extraordinary video in which he spoke in starkly personal terms about his experience as a Black man in America, his unequal treatment in the armed forces and the protests that gripped the country.