BOULDER, Colo. (CBS4/AP) — Federal prosecutors have charged a Boulder man with possessing hundreds of photos and videos of child pornography. Wesley Gilreath, 29, was arrested after his iPhone was found on a public bus in Boulder in late May.

Wesley Gilreath (credit: Boulder County)

Records say workers trying to find information about the owner discovered child pornography on the phone then contacted Boulder police, who called the FBI.

FBI Agent Justin Stern said the phone contained thousands of images, some “depicting the sexual abuse and/or torture of infants and/or toddlers.” It also contained web searches for violent child pornography and a search for a book about gaining children’s trust.

Gilreath is also accused of posting what he called the “Montana Hunting Guide” online. It listed mosque and synagogue addresses, as well as a refugee center, according to the arrest affidavit. Court records said FBI agents have seen similar documents used to plan attacks based on victims’ ethnicity, religion and other identifiers.

During an interview with investigators, Gilreath said he did not label himself a white supremacist, but wanted the white race to win at life. Gilreath described winning as having money and property, while not allowing others to take those resources.

He stated that he posted the “hunting guide” hoping that people would protest at the listed locations. He explained that he listed the particular locations refugees are in the United States illegally and are taking resources, many people do not like Muslims, the Bureau of Land Management takes land from people, and Jews are responsible for the refugee crisis.

In his written order, U.S. Magistrate Judge Scott Varholak said investigators found Gilreath had “numerous white supremacist documents and paraphernalia.”

Varholak said Tuesday that Gilreath was a danger and will be detained pending his trial.

The records also revealed that Gilreath tried to purchase a gun at a store in Boulder in May but was denied. An affidavit released Thursday indicated he was denied because denied because he was previously adjudicated as mentally defective or committed to a mental institution on March 21, 2016 (pursuant to Boulder County court case 2016-MH-129.) On the application, Gilreath listed his address as the Boulder Creek Apartments, in the 3600 block of Table Mesa Drive.

U.S. Attorney Jason Dunn said in a statement that Gilreath was still being investigated in relation to other possible crimes.

Dunn said the case shows authorities will use every available tool to prosecute federal crimes and to disrupt and prevent potential hate crimes.

RELATED: Reports Of Hate Crimes Nearly Doubled In Colorado In 2018

Gilreath’s attorney with the federal public defender’s office did not immediately return a message Wednesday seeking comment.

(© Copyright 2019 CBS Broadcasting Inc. All Rights Reserved. The Associated Press contributed to this report.)