Updated

A man who admitted to scheming to help the Islamic State extremist group has been sentenced to 18 years in prison in a case that prosecutors say involved plotting a never-realized bombing in New York City.

Munther Omar Saleh was sentenced on Tuesday in federal court in Brooklyn. The 22-year-old pleaded guilty last year to charges that he planned to help the Islamic State group. As part of his guilty plea, Saleh admitted that he had sought to communicate with and support the group and assaulted a federal officer.

Prosecutors said he escorted a co-defendant to an airport for a planned trip to join the Islamic State group overseas (the co-defendant was arrested before he could join the group), researched how to build a pressure-cooker bomb and discussed potential landmarks as targets with an Islamic State recruiter.

"I'm in NY and trying to do an Op," Saleh told a confidential source in an intercepted conversation, according to court papers.

Later, Saleh charged, while armed with a knife, at a federal officer who was watching him, prosecutors said.

"Saleh attempted to turn our city into a staging ground for violent attacks," William Sweeney, the assistant director in charge of the FBI's New York field office, said in a statement. Brooklyn U.S. Attorney Richard Donoghue said Saleh's sentence would deter "those who contemplate waging violent jihad in New York City at the direction of a foreign terrorist organization."

Saleh's lawyer, Deborah Colson, said her client was relieved that the case was concluded.

"Mr. Saleh is sincerely remorseful, and he is committed to making amends," she said in an email.

Saleh, an American citizen, was a college student when he was arrested in 2015. His case was linked to five other conspirators in New York and New Jersey. At least four of them also have pleaded guilty.

In a letter to the judge earlier this year, Saleh said he was drawn to the Islamic State group because he saw it as an "Islamic resistance movement" amid the Syrian civil war. He said he became alarmed and "started exercising very bad judgment" when he noticed law enforcement following him.

"I am sorry for my shameful behavior," he wrote.