Editor's note: The witnesses to the attacks in northeastern Nigeria have told CNN their names may be used in this article. Their names have now been added.
Kano, Nigeria (CNN) -- Scores of residents in four villages in the northeastern Borno state of Nigeria, near the border with Cameroon, were killed Tuesday in Boko Haram raids, a lawmaker and residents said.
They said hundreds of homes were destroyed.
Heavily armed gunmen dressed as soldiers in all-terrain vehicles and on motorcycles attacked Goshe, Attagara, Agapalwa and Aganjara villages in Gwoza district, shooting residents and burning homes.
Villagers fled into neighboring Cameroon to escape the onslaughts, said Peter Biye, a lawmaker from the area who serves in the Nigerian lower parliament.
"We are still trying to compile a toll of the dead as people on the ground are still counting the number of casualties," said Biye.
Residents of these villages fled their homes while soldiers have deployed in the area to fight the Islamists who have taken control of at least seven villages, the lawmaker said.
On Wednesday, military jets carried out aerial bombardment on Boko Haram positions in the affected area to dislodge the insurgents, he said.
Goshe resident Abba Goni said at least 100 people were killed in the village, but there is no independent confirmation.
"They laid siege on the village and opened fire with Kalashnikovs and fired RPGs (rocket-propelled grenades), burning the entire village with its 300 homes and a few mosques," said Goni, who fled to Gamboru Ngala town.
"We lost many people including vigilantes who tried to fight off the Boko Haram attackers."
At the predominately Christian village of Attagara, the insurgents set fire to homes and a church and killed dozens of residents, according to Bulus Yashi, who fled to Gamboru Ngala.
"It was a reprisal attack over the casualties Boko Haram suffered in the village in two previous attacks," Yoshi said.
On Sunday, around a dozen motorcycle-riding gunmen opened fire on a church in the village killing nine worshippers.
However, residents mobilized and pursued the attackers, killing four and arresting four others, Yashi said.
Villagers had repelled a May 25 attack on the village, killing seven Boko Haram gunmen, he said.
"We believed they came on a revenge mission," Yashi said.
Boko Haram Islamists have in recent times stepped up raids in northern Borno state near the border with Cameroon, Chad and Niger, pillaging villages, looting food stores and killing residents.
With no communication in the region because of the destruction of mobile phone towers by the insurgents, news of attacks is slow to emerge and verification of death tolls difficult to obtain.