The authority of spy agencies to do what they do derives from the people through their congressional representatives. Congress should zero out their funding. We can always start over without the bad apples.
Congress zeroing out their funding wouldn't necessarily kill them, it's a little more nuanced than that. For example, the CIA and Intelligence agencies by and larger are contributors to https://en.wikipedia.org/wiki/In-Q-Tel. Not to mention the funding they produce to generate funds within their black operations.