Nigerian troops repelled an attack on a military base in northeastern Borno state in which a soldier was killed and four others were injured, military and militia sources told AFP on Saturday.
On Wednesday jihadists from ISIS-affiliated Islamic State West Africa Province killed three soldiers when they temporarily seized control of another base in the town of Kareto, 200km away.
In the latest attack on Friday, the jihadists in several trucks carrying anti-aircraft guns attacked a base in the Kekeno village near the garrison town of Monguno, the sources said.
The militants were pushed back after a prolonged fight that lasted almost three hours with aerial support and reinforcements from Monguno.
"The terrorists made desperate efforts to overrun the base but were pushed back after heavy fighting," a military officer in Maiduguri said.
"Unfortunately we lost one soldier in the encounter and four others sustained injuries," the officer, who asked not to be named, added.
There was no indication of Boko Haram casualties.
Details of the attack were slow to emerge as telecommunications infrastructure has been destroyed by fighting and there are strict controls on movement in rural Borno state.
"The insurgents could not enter the base despite their number and heavy weapons," said a civilian militia fighting the jihadists who gave a similar account.
"I learnt one soldier was killed and a few others were wounded," the militia said,
Residents of Kekeno fled to Monguno following the attack, Monguno resident Adamu Sheriff said.
"Boko Haram attacked Kekeno around 1630GMT and engaged soldiers for almost three hours before they were forced out", said Sheriff who arrived in Maiduguri on Saturday.
It was the second attempt by Boko Haram to takeover the base in two months.
In September the jihadists made a failed attempt to seize the Kekeno base and were pushed back after hours-long battle.
The Nigerian military said on Saturday the spokesperson of an ISIS-affiliated Boko Haram jihadists faction was killed in the encounter with government troops.
In a statement on its Twitter account the military said Sale Ahmad Sale alias Baban Hassan identified as a member of Islamic State West Africa Province (ISWAP) was killed in a joint operation by the army and air force.
"The killing of the media leader is indicative of efforts by the NA (Nigerian army) to eliminate key members of the sect," the statement said.
The military did not say when the joint operation was conducted.
In September 2012 soldiers shot dead Boko Haram spokesperson Abul Qaqa at a checkpoint on the outskirts of Kano after he was tracked down through his phone signal.
The leader of Boko Haram offshoot Ansaru was also killed in a raid on his hideout in Kano around the same time.
Gali's death brings to three the number of Boko Haram's media commanders to be killed in the group's nine-year armed campaign to establish a hardline Islamic state in northern Nigeria.
In a December 2016 recording Boko Haram factional leader Abubakar Shekau said he executed the group's spokesperson Abu Zinnira over a plot to oust him as the leader.
In recent months, Boko Haram has carried out repeated attacks on military bases in Borno state, although the army has strongly denied reports of heavy troop casualties.
Nigerian authorities maintain the group, whose insurgency has left more than 27 000 dead since 2009, is on the verge of defeat despite an upsurge in attacks in recent months.