Mr. Rahimi was portrayed as a loner drawn to calls of jihad in online publications like Inspire.

On Tuesday, wearing a long beard and a kufi, a cap worn by many men in South Asia and parts of Africa, Mr. Rahimi complained in his statement about past harassment in airports over his traditional dress, and even before, when he did not have a beard and wore shorts “as if I’m going to the beach.”

He focused most of his brief statement on his father and a misconception that he believes had taken hold that the older man supported terrorism. “My house does not harbor any terrorist-type activities,” he said. Of his father, Mohammad Rahami, who attended Tuesday’s hearing in the rear of the gallery, he said, “He wants to give us a better future. I commend him for that.”

He mentioned the call his father made to the authorities in 2014 to report that the convicted man was behaving suspiciously. “We had our differences in life,” Mr. Rahimi said. “My father did his best to try to quell everything down.”

At this, Mr. Rahami, who spells his name slightly differently than his son, bowed his head in court and quietly sobbed.

In December, prosecutors said Mr. Rahimi had been giving other inmates access to speeches and lectures by Osama bin Laden and Anwar al-Awlaki and the same sort of bomb-making instructions from Inspire that were used as evidence at his trial. In his statement, Mr. Rahimi avoided discussing his part in these infractions, instead blaming the government for locking up the other inmates in the first place.

Of his own life, he said, “I have American friends and I also have Muslim friends.”

Judge Berman called his crimes “heinous, wanton, life-threatening” in handing down the maximum sentences for the eight crimes of which he was convicted. Mr. Rahimi already faced an automatic life sentence for one of the crimes, and Judge Berman added a second life term and, on top of them both, an additional 30 years in prison, all to be served consecutively. The redundant sentences would serve the same end — Mr. Rahimi is unlikely to ever leave prison — but could have individual practical implications should he prevail on an appeal of one or more of the convictions in the future.