Nicholas Young, right, with his father at Nick’s graduation from the Police Academy. Young is the only U.S. police officer to ever face terrorism charges — a case brought after he was under FBI surveillance during six of the 13 years he patrolled the D.C. Metro system. (Family photo)

A former police officer with the D.C. Metro system will spend 15 years in prison after getting caught in a terrorism sting operation, even as he continues to argue that he is not an Islamic State supporter but a misunderstood patriot.

Nicholas Young, 38, was found guilty at trial last year, after failing to convince a jury in Alexandria federal court that he was lured by law enforcement into lying for and giving financial support to a supposed Islamic State recruit. The recruit was actually an FBI informant, identified in court only as Mohammed.

“I’m sorry for letting my friends down, letting my family down,” Young, the first member of law enforcement to ever face terrorism charges in the United States, said in court Friday. “Those people in my life deserved better from me.”

But he also criticized the government, saying authorities misrepresented the body armor in his home and targeted him through an undercover informant “when I declined the government offer to spy on other Muslims in mosques.”

In a letter to judge Leonie M. Brinkema before sentencing, Young said “there is one thing that the government has not proven and will never prove: that I do not love my country and what it stands for.”

An image of Nicholas Young seized during a search of his home last year and filed in Alexandria federal court. (U.S. Attorney’s Office for the Eastern District of Virginia)

On Friday, Brinkema said she could not judge Young’s heart.

“You strike everybody as a very mild-mannered person,” she said. “You present yourself as a patriot.” But, she said, “We can’t look inside a human being. I have to look at the evidence.”

When Mohammed pretended to join the Islamic State abroad, Young lied to FBI agents and said the friend he met at a local mosque was on vacation. Then, after months of emailing with FBI agents posing as Mohammed, Young sent $245 in gift cards for the Islamic State.

“We expect police officers to protect and serve,” prosecutors John Gibbs and Gordon Kromberg wrote in court filings. “We do not expect them to thwart investigations of terrorist plots, or to advise others how to do so. We do not expect them to try to send money to terrorists, or advise others how to join” them.

Young, who converted to Islam in 2006, was under FBI surveillance for years before his 2016 arrest. Twice he traveled to Libya to fight with anti-government rebels there. His attorneys say they believe the investigation began with a dispute between Young and his superiors at the Washington Metro Transit Authority over the length of his beard and his workspace, where he kept a Koran. Young had also come into contact with undercover agents who were tracking other terrorism suspects in his circle.

At trial, prosecutors presented violent videos Young had watched and comments he had made about killing FBI agents and attacking federal buildings. In emails with Mohammed and conversations online, Young joked about terrorist attacks and suggested they were often justifiable. He described the rebels he fought with in Libya as “like-minded” with the Islamic State.

“For better or worse, I am a contrarian, and more often than not, to a fault,” Young wrote to the judge. “But. . . my willingness to engage with a friend on any subject matter under the sun, no matter how controversial, has never led me even to consider engaging in or supporting any act of terrorism against this country.”

Prosecutors also highlighted Young’s interest in Nazism, alleging he was a believer in an alliance between Islamist and white supremacist terrorism. He had dressed up as a Nazi officer in war reenactments and had a tattoo of an S.S. logo on his arm. He gave a neo-Nazi novel to a friend for his birthday.

“Whether it was meant in jest, whether it was not meant to be real... it’s your words,” Brinkema said Friday. “There is a real danger from someone like yourself.”

She noted the amount of weaponry Young owned, which included explosives and polymer guns that could evade metal detectors.

Young did not take the witness stand or offer any defense at trial. But in his letter, he said he committed his crime for personal rather than political reasons.

“I sent the gift cards not because my criticism of ISIS had somehow turned into genuine support for its immoral belief system, but out of a misplaced desire to support someone I thought was a friend,” he said.

Young did not elaborate on that support. But his mother Joy Young, in her own letter to the court, said Mohammed sent emails “pleading” for the gift cards “so he could call his family members.”

Other friends and relatives echo that claim. No such emails were presented at trial. In text messages shown in court, “Mohammed” said the cards would be used by the Islamic State to communicate with new recruits on an encrypted messaging application.

“Even now he has not been honest,” Kromberg said in court Friday.

Young’s friends and family in their letters to the court say that the man depicted at trial did not resemble the peaceable, tolerant person they know.

Young’s maternal great-grandfather was Jewish, his mother wrote, as was a girlfriend. Most of his friends from the Metro transit police were black.

“I never saw him treat people unfairly or without respect,” wrote Derrick Stokes, a fellow officer.

Young was also raised patriotic, his family said.

Joy Young worked at the CIA until her son was born. Her father was an Air Force officer. and her ex-husband was a history teacher. Young wanted to join the Army out of high school, but his parents said no. Instead, he went to college, where he discovered Islam, and in 2003 joined the Metro force.

But after his father’s unexpected death in 2007, the depression Young struggled with for years worsened, according to court filings.

“When our father died, I saw the light inside Nick go dim,” his sister Ashley Young wrote to the court.

Mohammed engaged Young in intimate conversations about his late father, defense attorney Linda Moreno said in court Friday, discussing a pregnant wife and the deaths of children abroad.

“This was. . .born out of Nick Young’s loneliness,” she said.

Prosecutors disputed that characterization, saying Young is still failing to confront his own motivations.

“The unfortunate fact is that he has an attraction to depravity that cannot rationally be explained,” they wrote.