Shelby County Sheriff's Office Alexander Nathan Barter had a plastic bag and knife on him when he was arrested by law enforcement.

A Texas man, through an advertisement he posted on the dark web, plotted to kill, sexually assault and eat a little girl, federal law enforcement said.

Alexander Nathan Barter, a 21-year-old resident of Joaquin, was arrested by Homeland Security agents on Oct. 19 on multiple felony counts, including criminal solicitation and conspiracy to commit capital murder.

According to a probable cause affidavit filed in Shelby County and first obtained by Lufkin’s KTRE-TV, the Texas Department of Public Safety launched an investigation into Barter after he posted an advertisement on the dark web seeking someone willing to let him commit necrophilia and cannibalism.

In the post, Barter allegedly provided two encrypted email addresses for responding to his ad. At least one individual answered the ad and offered his young daughter to Barter, authorities said.

“Nice! I’m in East Texas,” Barter replied, according to the affidavit. “How old is your daughter? Can we kill her?”

What Barter didn’t realize, the affidavit says, was that the individual he corresponded with was an undercover law enforcement officer pretending to be a dad in Brevard County, Florida.

The affidavit includes stomach-turning details about conversations in which Barter allegedly described how he planned to kill the child, have sexual intercourse with her body and cannibalize her.

In other online conversations, it was allegedly agreed that “father and daughter” would meet Barter at a Joaquin hotel. According to investigators, Barter told the undercover officer to purchase a burner phone and bring a change of clothes. The agent was further instructed to contact police upon his return to Florida and report his daughter had run away, authorities said.

“I’m not going to change my mind about this,” Barter allegedly wrote in one exchange. “I really want to do this.”

Authorities identified Barter after they subpoenaed the internet service provider used to exchange the messages, the affidavit says.

Barter was arrested by Homeland Security agents at his home in Joaquin. The arrest was made as he was leaving to carry out his plan, the affidavit alleges. At the time of his arrest, Barter was carrying a plastic bag and a knife ― items he mentioned during an email exchange with the undercover officer, authorities said.

After being read his Miranda rights, Barter confessed to making the post on the dark web and to planning the crimes, according to the affidavit.

The Light and Champion reported Barter is a former student of Joaquin High School and attended Panola College. He formerly worked with a local ministry and as a laborer at a food processing plant, according to social media posts the outlet found.

Barter is being held at the Shelby County Jail. District Attorney Stephen Shires said Barter will not be allowed to post bond.

“This terrible incident is another reminder that parents should always remain vigilant and know what their children are doing on the network,” Shires said in a statement.

Send David Lohr an email or follow him on Facebook and Twitter.

CORRECTION: An earlier version of this article misidentified the arresting agency as the FBI; the suspect was apprehended by Homeland Security agents.