The convicted soldier, Hassan Adamu, a lance corporal, had told the court that he shot the deceased on December 23, 2015 in self defence.
He said the victim attempted to disarm him while he was on guard duty at the popular Monday market, Maiduguri.
He narrated that the deceased came from nowhere screaming Allahu Akbar, and running towards his duty post. The jailed soldier said he was able to dislodge the attacker whom he said continued to hold on to the nozzle of his rifle. He said he had to shoot even though other soldiers came to back him up.
But the testimonies of various non-military prosecution witnesses at the court martial were in conflict with that of the soldier.
Most of them said the shooting was unprovoked, even though some said they actually heard the victim shouting Allahu Akbar in the manner most Boko Haram terrorists do before carrying out attacks.
The court said the convicted soldier could have exercised more restraint in overpowering the victim who was found to be unarmed.
Besides, the court said, the action of the soldier, though carried out while on lawful duty, was against relevant laws of the Nigeria Armed Forces.
The court martial also jailed a private soldier, Egbechi Oze, for 14 months for absconding from his duty post for about 270 days, while taking refuge somewhere in southeast Nigeria.
The soldier was counted among those missing when Boko Haram attacked a military base in Gwoza. The soldier, according to the court, continued to enjoy his emoluments while staying away from his duty post for nearly one year.
He was also charged for not accounting for his rifle and cache of ammunitions he signed to be in his possession during the attack on Gwoza.
He was however acquitted for the missing rifle and ammunition on the grounds that he lost possession of them when he was abducted by Boko Haram insurgents before soldiers attacked the place.
The court explained that a soldier that is jailed by the court marshal, stands dismissed as such soldier cannot be reabsorbed into the Nigeria Army.