There are protocols for this sort of thing, so a given department takes the lead by default. On national security for example the FBI does the counter-intelligence investigations, but obviously affected agencies can, and do, decide to feed disinformation instead of allowing an arrest to proceed. This needs coordination to overcome the faction thing.