They defy the principles of the Federation in order to protect them, which is one of the reasons why Section 31 is not officially sanctioned by Starfleet, and its very existence is not acknowledged openly.
Section 31 unsuccessfully tried to recruit Julian Bashir on repeated occasions.
During the Dominion War, among other questionable actions, they engineered a genocidal virus to exterminate the Founders of the Dominion. They also meddled with Romulan internal politics and were said to have had an agent on the Klingon High Council.