This isn't that hard.
Trump could fire Gina, Wray, or Coates anytime he wants.
He hasn't. Ergo there is a reason.
I think they are all grey hats playing their parts for a reason
It could just be that they need to maintain IC loyalty to prevent worse shit from happening.
Thus they are playing the part of defending IC honor and secrecy even while exposing them surreptitiously.