Facebook Inc. says it has removed hundreds of fake pages and accounts linked to Iran and Russia that were part of co-ordinated misinformation campaigns on the platform, as tech companies scramble to shore up their defences against possible foreign interference in U.S. midterm elections in November.

The social media giant said on Tuesday it had taken down more than 650 pages, groups and accounts involved in several separate campaigns linked to Iranian and Russian governments.

A tip from cybersecurity firm FireEye led company officials to investigate a group called Liberty Front Press. The organization operated accounts and pages that claimed to be run by an independent Iranian media organization focused on news about the Middle East, U.S., U.K and Latin America. Facebook said the group, which had about 155,000 followers and had spent US$6,000 on Facebook ads, was linked to Press TV, an Iranian state-owned English language news network.

Story continues below advertisement

The groups were linked to organizations that also engaged in cybersecurity attacks, including trying to hack into users’ accounts and spread malware, company officials said.

The social media firm further revealed it had been tracking a second Iranian-backed campaign since last August, which had more than 813,000 followers and shared content about Middle East politics in Arabic and Farsi, along with posts about U.S. and U.K. politics in English.

Facebook officials said that group, which first appeared on Facebook in 2011, had also spent US$6,000 on ads and organized 25 events on the platform.

Company officials said they had briefed the U.S. Treasury and State Departments in case the activity involved any potential violations of U.S. sanctions, which don’t prohibit U.S. companies from providing internet services to Iran.

Separately, Facebook said it had removed pages and accounts linked to Russian military intelligence services, including some that had been identified as attempting to meddle in the 2016 presidential election.

The pages mainly focused on spreading pro-Russia and pro-Assad news about Syria and Ukraine. Facebook officials said they had found no evidence that these pages were targeting the U.S. and declined to say whether there was evidence the groups were attempting to influence upcoming U.S. midterm elections.

“We’re still investigating and there’s a lot that we don’t know,” said Facebook chief executive Mark Zuckerberg.

Story continues below advertisement

The pages are the latest in tech and social media firms’ struggles to prevent a repeat of the foreign interference in the 2016 presidential election. Last month, Facebook removed 32 pages and profiles that had bought ads and organized events to inflame political debate around divisive social issues, such as immigration, ahead of the November midterm vote.

Shortly after Facebook publicly revealed its latest findings, Twitter said it had banned 284 accounts originating in Iran for “co-ordinated manipulation.”

Microsoft on Tuesday said it had found hackers with ties to the Russian government that were targeting U.S. political groups, by creating fake websites for two conservative U.S. think tanks, and three sites made to look as if they were affiliated with the U.S. Senate.