> So when the CIA tells me some foreign government is doing something bad, I should believe them?
Honestly, yes.
> Then when the CIA denies they lied about the foreign government was doing something bad
When have they done this? A few times probably, but not really a high percentage.
At any rate, P(CIA telling the truth about a foreign govt|foreign govt is doing something bad) is much higher than P(CIA lying about foreign govt|foreign govt is not doing something bad). The rational thing is to put higher weight on such statements than when the CIA is trying to cover their own ass.