CONCORD, N.H. — A Maine man will spend nearly three years in prison for attempting to extort a New Hampshire woman using sexually explicit photos of her stored on a laptop he stole from her.

Federal officials say 23-year-old John Bryan Villegas of Kittery, Maine, was sentenced to 33 months in prison Thursday in U.S. District Court in Concord.

U.S. Attorney John Kacavas says Villegas pleaded guilty to a cyber-stalking crime known as “sextortion.” Officials say Villegas stole the woman’s laptop during a burglary, then threatened to send explicit images to her neighbors and friends if she did not send him sexually explicit pictures and video of herself.

Villegas pleaded guilty to the federal charge in September. He was convicted of burglary in state court in January.