The former Marine suspected to have shot an Idaho pastor who had endorsed Ted Cruz at a weekend rally was apprehended by Secret Service after throwing flash drives over the White House fence Tuesday night.

Law enforcement confirmed late Tuesday that Kyle Odom was in custody after throwing the drives over the south fence toward the president's residence around 8:30 p.m. EST, according to a statement from the U.S. Secret Service.

After Odom was arrested at the White House, his name was processed through a national database where a warrant in Idaho triggered the attention of D.C. officials

Police have been looking for Odom since Sunday afternoon, when he allegedly shot Pastor Tim Remington six times as the pastor was leaving church Sunday afternoon. Authorities have not explained how Odom was able to make it from Idaho to Washington, D.C., in approximately two days.

Remington of Altar Church in Coeur d'Alene, Idaho, led a prayer at a Cruz rally Saturday. He is expected to survive his multiple gunshot wounds.

Law enforcement confirmed the victim was still unconscious Monday, but in fair condition at Kootenai Health.

"We pray for his full recovery and are thankful for the efforts of law enforcement to ensure the attacker is swiftly brought to justice," the Cruz campaign said in a statement Monday.

Police do not know Odom's motive, but said witnesses confirmed Odom attacked Remington from behind when the pastor left church and had been getting into his car.

Odom does not have a criminal record, but does have a history of mental illness, according to the police.

Remington, married with four children, has previously been threatened by inmates he has counseled at a local prison.