Wichita, KS–A Leavenworth man who bragged on the Internet about sexually abusing a 4-year-old girl was sentenced Monday to 20 years in federal prison for distributing child pornography, U.S. Attorney Tom Beall said.

Joshua Grimm, 33, Leavenworth, Kan., pleaded guilty to one count of distributing child pornography. At sentencing, a prosecutor said the investigation started in June 2016 when Grimm began communicating with a detective in Arizona who was working undercover.

In a chatroom conversation, Grimm told the detective that he had sexually abused a 4-year-old-girl and he sent a photo of the girl. At the time, child molestation charges were pending against Grimm. He told the detective he had “thought about kidnapping a young girl from a park or busy store.”

Beall commended the FBI, an Internet Crimes Against Children Task Force in Arizona and Assistant U.S. Attorney Kim Flannigan for their work on the case.