Washington CNN —  

The FBI arrested Joshua Van Haften, 34, of Madison, Wisconsin, on Wednesday at Chicago’s O’Hare International Airport after returning “in custody” from Turkey where the Justice Department alleges he attempted to join ISIS.

Van Haften departed the U.S. in August 2014, leaving behind a trail of radicalized social media postings and a number of concerned roommates and associates who were aware of his radical ideology, according to the FBI complaint.

A spokesperson at the Western District of Wisconsin U.S. Attorney’s office said Van Haften had been in the custody of Turkish immigration officials since late October.

No stranger to law enforcement, Van Haften has been in and out of trouble for an array of charges, some violent – such as battery and pointing a firearm at someone – and also a conviction for sexual abuse on a child in 1999.

READ: Cyberattack disables 11 French TV channels

According to statements made online to jihadists known to the FBI, Van Haften was attempting to cross into Syria in an attempt “to provide material support and resources, namely himself as personnel,” to ISIS.

But this proved more difficult than Van Haften anticipated.

“I was about to cross to Syria the day before the Americans through Saudi and UAE, started bombing in Syria from their ships,” he told a former roommate via Facebook messages, which were shown to the FBI.

“I was gonna be in the very city they bombed. But I didn’t make it. Hopefully soon though,” he said.

In October 2014, after paying a jihadist smuggler his last 100 lira to help him cross into Syria, he was dropped off in the country by some “young brothers” who said his transportation across the border would arrive soon.

“I waited for three hours with no one showing up in the middle of nowhere,” Van Haften said on Facebook.

He was forced to walk to the nearest village in Turkey, which he calls “Gunderen,” where he slept on the floor of a mosque under the wary eye of an imam who Van Haften assessed was not sympathetic to ISIS ideology.

“The imam looked at me as strange as could be while making wudu. He offered me a blanket and let me sleep a few hours before Jumuah. But he was totally against Dawlah, so I wasn’t getting any help across. He paid my way back to Istanbul tho,” Van Haften posted.

Van Haften’s first signs of radicalization became known to the FBI in July 2014 when a former associate of his was interviewed by federal law enforcement official who learned he had expressed his desire to travel to Syria and Libya to join Jabhat Al-Nusrah, another radical terrorist group based in Iraq and Syria.

In addition to other former roommates and acquaintances recalling odd behavior and jihadist chatter, a strange encounter with Van Haften by two strangers further raised red flags. Just days before he is believed to have left for Turkey, a mother recalled her 11-year-old son being approached by an unidentified man outside the Wisconsin capitol building. The son would later tell his mother, who relayed the information to an FBI agent, that the man “talked about WW III, Syria and leaving the United States to go to Syria.”

Less than a month later, the FBI agent showed the mother and son a picture of Van Haften, who they identified as the man that approached the 11-year-old boy.

While in Turkey, Van Haften continued to interact with jihadists and post radical messages on social media and listing his location as “Kucuk Istanbul Sanliurfa Turkey,” indicating he was very close to the Syrian border.

Numerous statements made by a known jihadist based in Raqaa, Syria, the self-described capital of the “Islamic State,” on Facebook that were “liked” by Van Haften further indicated his willingness to support the terror organization, according to federal law enforcement investigators.