Amid the controversy surrounding White House National Security Adviser Michael Flynn’s alleged conversations with Russia, it may be instrumental to recall that representatives for Barack Obama’s 2008 presidential campaign were accused of meeting with Hamas and Iran.

Depending on what took place, the alleged contacts with Iran may have violated the Logan Act, which bars citizens from negotiating with foreign governments in dispute with the United States. It may be questionable whether Hamas, which rules the Gaza Strip, legally qualifies as a foreign government.

In 2008, Robert Malley stepped down as an informal foreign policy adviser to Obama’s campaign when it was revealed that he met with Hamas members.

Malley admitted to the meetings, but he claimed he met with the terrorists as part of his private job.

“I have never hidden the fact that I had meetings with Hamas,” Malley wrote in an open letter published in the New York Times. “I do this as part of my job as Middle East program director at the International Crisis Group.”

He said he distanced himself from Obama’s campaign because the Hamas meetings were “becoming a distraction to me and to Senator Obama’s campaign, and to avoid any misperception — misrepresentation being the more accurate word — about the candidate’s position regarding the Islamist movement.”

Malley later joined the Obama administration. In 2015, he was appointed to lead the Middle East desk of the National Security Council.

He was also named Obama’s special adviser regarding the Islamic State.

Meanwhile, in August 2014, Michael Ledeen, a former consultant to the National Security Council and U.S. Defense Department, penned a column at PJ Media stating Obama opened a back-channel to Iran during the 2008 presidential campaign. Ledeen said the back channel went through retired Ambassador William G. Miller, who also led the 1979 negotiating mission during the Iran hostage crisis. Ladeen wrote that Miller confirmed his back-channel involvement to him.

Ledeen wrote:

The actual strategy is detente first, and then a full alliance with Iran throughout the Middle East and North Africa. It has been on display since before the beginning of the Obama administration. During his first presidential campaign in 2008, Mr. Obama used a secret back channel to Tehran to assure the mullahs that he was a friend of the Islamic Republic, and that they would be very happy with his policies. The secret channel was Ambassador William G. Miller, who served in Iran during the shah’s rule, as chief of staff for the Senate Select Committee on Intelligence, and as ambassador to Ukraine. Ambassador Miller has confirmed to me his conversations with Iranian leaders during the 2008 campaign.

The Logan Act states:

Any citizen of the United States, wherever he may be, who, without authority of the United States, directly or indirectly commences or carries on any correspondence or intercourse with any foreign government or any officer or agent thereof, with intent to influence the measures or conduct of any foreign government or of any officer or agent thereof, in relation to any disputes or controversies with the United States, or to defeat the measures of the United States, shall be fined under this title or imprisoned not more than three years, or both.

Aaron Klein is Breitbart’s Jerusalem bureau chief and senior investigative reporter. He is a New York Times bestselling author and hosts the popular weekend talk radio program, “Aaron Klein Investigative Radio.” Follow him on Twitter @AaronKleinShow. Follow him on Facebook.