Starfleet has always been corrupt. The sheer number of renegade Captains and Admirals is all the proof we need.
Then again, in any series, we are only witnessing a handful of each of the most dramatic (some would say "exciting") moments in The United Federation of Planets' day-to-day operations; it would be safe to say it oftentimes functions as intended.