Federal prosecutors investigating Rudy Giuliani’s activities in Ukraine have closed their probe after more than two years and said no criminal charges will be filed.   

  Prosecutors with the U.S. Attorney’s office for the Southern District of New York have been investigating Giuliani, former President Donald Trump’s former personal attorney, for possible violations of foreign lobbying laws since early 2019.   

  On Monday, they informed a judge overseeing the investigation that they had closed the case.   

  The notice came in a court filing with prosecutors asking the judge to terminate the special master appointed to oversee the review of documents obtained when the FBI executed a search warrant at the former New York mayor’s home in April 2021.   

  “The Government is writing to inform the Court that the grand jury investigation leading to the issuance of the aforementioned warrants has been completed and that based on information currently available to the Government, no criminal charges are pending,” prosecutors wrote.   

  A spokesman for the US attorney’s office declined to comment.   

  “This is great, long-awaited news,” said Robert Costello, Giuliani’s lawyer.  “Unfortunately, Mayor Giuliani had to spend two and a half to three years with that cloud over his head.”   

  The end of the investigation also closes a chapter from the Trump administration that involved two South Florida businessmen, shadow diplomacy efforts including a plot to oust the US ambassador to Ukraine and an impeachment trial of the former president.   

  Prosecutors had been looking into whether Giuliani violated foreign pressure laws by acting on behalf of Ukrainian officials when he sought the removal of then-U.S. Ambassador to Ukraine Marie Yovanovitch while urging Ukraine to investigate Trump’s 2020 political opponent, then-Democratic Pres. candidate joe biden.  , and his son Hunter.   

  US law requires anyone lobbying on behalf of a foreign government or official to register, and failure to do so is a violation.   

  Giuliani had claimed that his activities in Ukraine were done in his capacity as Trump’s lawyer and that he “never represented a Ukrainian national or official before the United States government.”   

  In April 2021, federal agents executed search warrants at Giuliani’s Manhattan apartment and Park Avenue office, seizing 18 electronic devices.  Prosecutors also revealed they had secretly searched Giuliani’s iCloud account in 2019. Earlier this year he met with prosecutors and provided passwords for some of the locked devices.   

  Greenlighting the search warrants — specifically against a former president’s personal lawyer — was one of Attorney General Merrick Garland’s first high-profile moves in the early days of the Biden administration.   

  Giuliani’s role as the then-president’s lawyer and his involvement with Ukrainian officials added complexity to the investigation, people familiar with the matter told CNN.  It was unclear whether Giuliani received compensation from Ukrainians and publicly touted his efforts, which could make it difficult for prosecutors to prove he secretly lobbied for foreign actors.   

  Two South Florida businessmen, Lev Parnas and Igor Fruman, helped introduce Giuliani to Ukrainians and translate for him on trips.  Once considered potential witnesses in the government’s case, they were caught up in their own campaign finance and fraud scheme, and both were found guilty or pleaded guilty.   

  The decision to close the investigation also shows the challenges the Justice Department has faced when trying to enforce foreign lobbying laws, an area of ​​increased focus because of potential national security risks.   

  Earlier this month, Trump ally Tom Barak and his former aide were acquitted of acting as unidentified foreign agents of the United Arab Emirates.   

  The New York investigation isn’t the only legal threat Giuliani faces.  His actions trying to sway the results of the 2020 election to favor Trump have drawn scrutiny and potentially costly fines or settlements.  Dominion Voting Systems filed a multi-billion dollar defamation suit against Giuliani over his baseless allegations of voter fraud.   

  Giuliani has been told he is the target of a criminal investigation being conducted by a special jury in Fulton County, Georgia, which is looking into Trump’s efforts to influence the election in his favor.  He appeared before a grand jury in August.   

  Federal prosecutors are also conducting a broad investigation into efforts to interfere with the transfer of power from the Trump administration to the Biden administration.   

  This story has been updated with additional details.