nigeria suicide blast
Nigerian girls blow themselves up in market Pictured: Smoke is seen after an suicide bomb explosion in Gombe, February 1, 2015. (Representative Image)Reuters

A suicide bombing has killed at least 25 people at a mosque in the Nigerian city of Maiduguri, a media report said.

Scores were wounded in the attack on Saturday, that followed an overnight assault on the north-eastern city by the militant group Boko Haram, Xinhua reported, citing eyewitnesses.

The suicide bomber blew himself up inside a mosque near the local market and corpses were seen lying on the floor, said Yusuf Ali, a witness.

A rescue worker said more than 25 bodies were evacuated at the scene of the blast.

Most officials declined to comment on the casualties' figure.

A Muslim cleric, Yushau Danjuma, said the bomber strolled into the mosque, pretending to be part of the congregation.

"I noticed when he came. I thought he entered the mosque to join others to pray but soon as the prayers started, he detonated the explosive devices wired round his body," he said.

The attacks came just hours after Muhammadu Buhari was sworn in as Nigeria's new president. He has vowed decisive action against Boko Haram.

In recent years, the militants have killed thousands of people -- mostly in north-eastern Nigeria -- in its attempt to set up an Islamic state.

So far no group has claimed responsibility for the bombing.

Late on Friday, Boko Haram fighters fired rocket-propelled grenades into the southern suburbs of Maiduguri.

The Nigerian army deployed armoured vehicles and fired back, forcing the militants to retreat.

In his first speech as president on Friday, Buhari reiterated his commitment to tackle the group, which he described as a "godless group, who are as far away from Islam as one can think".

Buhari, a former military ruler, has taken over from Goodluck Jonathan, who had been in office since 2010.

Nigeria's new president has also promised that the government would do everything it can to rescue more than 200 Chibok girls who were captured last year by Boko Haram.

He is the first opposition figure to win a presidential election in Nigeria since independence in 1960.

Kashim Shettima, governor of the northern Borno state, said security operatives had commenced investigation on the incident which he described as "an act of cowardice".