The owner of the gun that was used to kill a University of Utah student last fall — which the man had loaned to the murderer in exchange for $400 — has pleaded guilty to a federal charge.

Nathan Vogel, 21, told the court Monday that he deceived a licensed Salt Lake City dealer to purchase a .40-caliber pistol in September. As part of a plea agreement, he will avoid a potential sentence of up to 10 years in prison, instead getting credit for time served and being on supervised release for three years.

The deal comes shortly after the U. closed its investigation into the case.

“Mr. Vogel has taken responsibility for his unlawful conduct and is now a convicted felon,” said U.S. Attorney for Utah John Huber in an emailed statement. “He is prohibited from possessing a firearm in the future.”

Vogel was also initially charged with conspiring to commit an offense against the United States, which is considered the victim in this case; that has since been dropped. All of the charges were related to his purchase of the gun, rather than his decision to loan it to Melvin S. Rowland.

But Vogel was indicted for the illegal buy only after police discovered that he provided the pistol to Rowland, a 37-year-old convicted felon who wasn’t allowed to have one. Vogel told officers that he and Rowland had worked together as security guards — which is why he got the gun — and Rowland knew he was short on cash.

Rowland offered Vogel $400 to borrow the gun, which Vogel thought he was using to teach his girlfriend to shoot. “He manipulated me using the guilt trip to use my weapon,” Vogel said in a recently released police report.

Instead, Rowland used it to kill student-athlete Lauren McCluskey outside her campus dorm on Oct. 22. He died hours later by suicide.

McCluskey, 21, had ended her brief relationship with Rowland after finding out that he had lied to her about his age and background. For several days after that, she called campus police to report that he was extorting and harassing her. But, according to a later review of the university’s response, officers never discovered Rowland was on parole and did little to address McCluskey’s concerns.

They also never heard from housing officials, who learned from McCluskey’s friends that Rowland had talked about bringing a gun to campus.

In an October news conference shortly after McCluskey was killed, University of Utah police Chief Dale Brophy said Vogel contacted officers when he saw the news about Rowland and the slaying. At that point, Brophy said it was unlikely that Vogel would be prosecuted.

“We don’t believe at this time that [the friend] had any knowledge that Rowland was a convicted sex offender and on parole,” the chief added.

But Jill McCluskey, McCluskey’s mother, had in November called for charges to be filed against the person who gave Rowland the firearm. And she has previously said that she’s glad the U.S. Attorney’s Office was moving forward with a case “against the individuals who lied and conspired to buy the gun that was used to kill our daughter.” She declined to comment Monday.

To charge Vogel under state law in connection with the loan, prosecutors would have to be able to show that he knowingly gave the gun to aid in the crime or knew that Rowland couldn’t own a gun because of his background. Officers have said neither apply. But Vogel’s own acquisition of the gun was illegal, federal prosecutors contend.

Vogel had been generally discharged from the Army — a step below an honorable discharge — and thought that might stop him from getting a gun. So he brought along a friend, Sarah Emily Lady, 24, who underwent the background check instead. Immediately after the purchase, according to court documents, she handed the weapon over to Vogel. That is against the law.

And, despite what Vogel thought about his release from the Army, there is no restriction on those with general discharges owning a gun. Under current law, if he had purchased the gun himself, he may not have faced charges despite loaning it to Rowland.

“As we mentioned when the case was indicted, straw purchases are illegal for a reason. When a firearm is unlawfully acquired or transferred, it increases the likelihood that the firearm will end up in the wrong hands,” Huber added. “We offer our condolences, once again, to the family and friends of Lauren McCluskey.”

Vogel’s sentencing is set for Sept. 11. Lady has, so far, pleaded not guilty to the same charges.