A Pennsylvania man who illegally sold $1.5 million in bitcoin to undercover federal agents and others was sentenced Wednesday to a year and a day in prison and will be required to surrender $40,000 he made in commissions.

In one of the first cases of its kind, Eldon Stone Ross, 24, had been charged with conducting an unlicensed money transmitting business between January 2015 and November 2016 and failing to report the cash-to-bitcoin and bitcoin-to-cash transactions.

"We don't see many of these cases," said Bert Glenn, the assistant U.S. Attorney who prosecuted the case in Philadelphia. "It's the first I've done here."

Bitcoin is a virtual currency that has legitimate uses. However, due to the relative anonymity it provides users, it's often a preferred method of payment for illegal goods and services bought on the darkest corners of the Internet.

Commercial institutions such as Coinbase, which operate legal cryptocurrency exchanges, are required by federal law to report any suspicious transactions involving more than $10,000 in cash to the Department of the Treasury as a safeguard against money laundering, extortion, and other illicit activities.

"If people can go to someone like Ross who is dealing outside the institutional market, it adds to their anonymity," Glenn said.

Ross admitted in October to selling $50,000 worth of Bitcoin to undercover agents working with Homeland Security Investigations. In each case, he "failed to obtain identifying information from the agents," according to court records.

Ross, of Kennett Square, previously had been convicted in 2014 on felony charges of trafficking heroin and sentenced to up to 23 months in Chester County. He was apparently in jail during part of the period in which he admitted to operating the money transmitting business. According to court records, Ross petitioned to be released on house arrest in February 2015.

In addition to the year-long federal prison term, Ross will be required to serve three years of supervised release.