Two Somali nationals granted refugee status in the United States are accused of attempting to join the Islamic State (ISIS) and sought to obtain American citizenship.

Last month, the Department of Justice (DOJ) announced that 21-year-old Ahmed Mahad Mohamed and 20-year-old Abdi Yemani Hussein — both refugees in the U.S. from Somalia — were arrested on suspicion that they were planning to join ISIS.

According to court records, Mohamed and Hussein were in communication with an undercover FBI agent who they believed was a supporter of ISIS. In these communications, law enforcement officials allege that the two refugees expressed their desire to travel to Egypt to fight for ISIS or plot an attack on American citizens on behalf of ISIS.

Ultimately, the pair bought flights to Egypt in an effort to fight for ISIS but were instead arrested by federal agents at the Tuscon International Airport in Arizona.

Details provided to Breitbart News reveal how Mohamed and Hussein had planned to use the U.S. legal immigration system to obtain permanent residence, otherwise known as green cards, and to eventually become naturalized American citizens — making them non-deportable residents.

Mohamed first arrived in 2014 under the Obama administration from Somalia as the child of a refugee. A year later, Mohamed was approved by U.S. federal immigration officials to adjust his status and become a lawful permanent resident, known as a green card holder.

At the time of his arrest, Mohamed had been attempting to become a naturalized American citizen.

Likewise, Hussein first arrived in 2014 under the Obama administration from Somalia as the child of a refugee and was in the process of requesting a green card from the federal government at the time of his arrest. Obtaining a green card would have allowed Hussein, like Mohamed, to eventually apply to become a naturalized American citizen.

The Obama administration resettled roughly 54,500 Somali refugees in the U.S. between 2009 and 2016 — with nearly 99 percent being followers of Islam. Compare this mass inflow to recent years under the Trump administration where less than 3,000 Somali refugees have been resettled in the country, almost all of whom are Muslim.

John Binder is a reporter for Breitbart News. Follow him on Twitter at @JxhnBinder.