A federal agent who launched the investigation that ultimately led to the resignation of Central Intelligence Agency chief David Petraeus was barred from taking part in the case over the summer due to superiors' concerns that he had become personally involved in the case, according to officials familiar with the probe.

New details about how the Federal Bureau of Investigation handled the case suggest that even as the bureau delved into Mr. Petraeus's personal life, the agency struggled with questionable conduct by one of its own—including allegedly sending shirtless photos of himself to a woman involved in the case.