A Secret Service agent was found dead last week in the midst of an investigation into an apparent suicide. Rafael Prieto was being investigated by the agency after rumors of an alleged affair bubbled to the surface during an internal crackdown on agent behavior following the recent Secret Service prostitution scandal in South America.

Prieto, 47, was in on security detail for President Barack Obama, and at one point in his career, he was in charge of security for White Plains, N.Y. Prieto was not on duty at the time of the suicide in White Plains, which is located just north of Manhattan. He had been on the detail responsible for Bill Cinton, while the former commander-in-chief was visitng New York City.

Prieto was a married father who had been having a years-long affair with a Mexican woman. The affair was not punishable by law but an agent of Prieto’s status would have been required to disclose the relationship to higher-ups, according to the Associated Press.

The woman apparently posed no threat to national security. 

"Rafael Prieto had a distinguished 20-year career with the Secret Service that was marked by accomplishment, dedication and friendships," agency spokesman Edwin Donovan said in a statement to the AP. "The Secret Service is mourning the loss of a valued colleague."

Metropolitan Police and the local medical examiner were investigating the death, reportedly caused by carbon monoxide poisoning. Preito was found dead in a closed car garage with the engine running.

Politico reported he was a well-liked veteran of 22 years on administrative leave at the time of the suicide. Prieto was facing a slew of agency charges that included dismissal for failing to notify the Secret Service of his secret relationship. He was married to his wife since 1993.

The Secret Service -- which is responsible for protecting the president, vice president, their families, visiting dignitaries, and investigating counterfeit crimes -- has placed agents under increased scrutiny since an April scandal in Cartagena, Colombia. After arriving days before President Obama landed in South American the thirteen Secret Service agents allegedly went out for a night of hard partying and brought prostitutes back to their hotel.

The news went public after agents refused to pay the prostitutes, engaging in a loud argument in the hotel.

Prieto was not in Columbia at the time, according to NBC News.