His first term focused on America’s rival superpowers. Now the emphasis is on homeland defense and troops on city streets.