From one perspective, Lawal Babafemi was a propagandist for Al Qaeda who traversed several countries to join in jihad, and was plotting to carry out an important mission when he was arrested in 2011.
From another, he was a desperately poor Nigerian who was sexually abused as a child, was kept from graduating from college because of bureaucratic malfunctions, and faced torture by Nigerian officials after embracing and then turning away from terrorism.
On Wednesday, Mr. Babafemi was sentenced to 22 years in prison in Federal District Court in Brooklyn, having pleaded guilty in April 2014 to providing and conspiring to provide material support to a terrorist group. Federal sentencing guidelines called for a term of 24 to 30 years; the defense had asked for 15.
Mr. Babafemi told Judge John Gleeson that he was “extremely sorry” and that he now denounced Al Qaeda. His lawyer, Lisa Hoyes, noted that he had been advising another of her clients — who is in jail on charges of trying to join ISIS — to avoid terrorism.
“It’s hard to conjure a more serious offense,” Judge Gleeson said in handing down the sentence. He noted, however, that Mr. Babafemi’s recent denunciations of terrorism factored slightly in his favor. “I wish I had a better feel for how genuine it is,” the judge added.
Mr. Babafemi, about 35, was born in Nigeria. When he was 2, his parents separated — his father had several wives, Mr. Babafemi said in a letter to the judge. After that, he saw his father only three more times.
His mother hauled timber to a sawmill six days a week to support him and his four siblings, and “there were many cases of people dying in this forest due to the attack from the wild animals,” Mr. Babafemi wrote.
Mr. Babafemi was often left in day care or watched by older family members, and he was sexually abused by some of them until he was 10, according to a sentencing memorandum filed by Ms. Hoyes.
In Lagos, violent student groups known as cults shut down his college’s operations. After an identification mix-up, he had to repeat his first-year courses, and professors said they lost exams, so he did not get credit for some classes. Mr. Babafemi did not graduate despite paying for and attending for six years.
He married a childhood friend, a woman named Nike, in 2007, and tried to start a fish-farming business. Suppliers, however, lied to him about the species they sold, and power failures made maintaining fresh water for the fish impossible, the memorandum said.
Nike had a stillborn baby and several miscarriages before delivering two children.
In 2010, Mr. Babafemi went to Yemen, apparently wanting to join Al Qaeda in the Arabian Peninsula. He did not explain why.
Zainab Ahmad, an assistant United States attorney, said at the sentencing that Mr. Babafemi could have joined terrorist groups closer to home, but instead joined a group that was targeting the United States.