The attorney general has confronted an unrelenting succession of politically sensitive investigations, underlining the intensely polarized environment he is operating in.