Ted Ullyot, general counsel at Facebook, is leaving the social network to take time off, according to AllThingsD.

Facebook confirmed the departure yesterday. Ullyot, 45, will depart in July. The search for his replacement is going to include outside and inside candidates.

Ullyot had a tough job, overseeing controversial legal issues ranging from Facebook’s ownership battle with the Winklevoss twins to investor lawsuits over the company’s initial public offering. He also had to stand guard on privacy issues related to the company’s giant social network.

Ullyot joined Facebook in the fall of 2008. At that time, he had been a high-powered Washington, D.C. lawyer who previously held senior legal positions at AOL, the law firm Kirkland & Ellis, and the U.S. Attorney’s Office.