Islamic militants purchase a nuclear device from a sympathetic official in Pakistan and ship the weapon on the flip side of a drug trafficking route through West Africa to South America. Next, the package is smuggled north to the United States-Mexico border.

Although this sounds like the plot line of a spy thriller, it is a scenario laid out in an online magazine produced by the Islamic State, the apocalyptic Syria-based terror group also known as ISIS.

“From there it’s just a quick hop through a smuggling tunnel and … presto, they’re mingling with another 12 million ‘illegal’ aliens in America with a nuclear bomb in the trunk of their car,” the 2015 ISIS article says.

The debate over security along the US-Mexico border isn’t just about the millions of unauthorized migrants who have crossed the international boundary seeking work and better lives. And it isn’t just about the drug smugglers and assorted other criminals who routinely use the border as an easy back door into America.

There is potentially a greater threat from a porous southern border.

Conservatives have long warned that terror groups like ISIS and Al Qaeda might try to exploit drug and migrant smuggling routes from Mexico to sneak into the US undetected.

The threat isn’t merely speculative.

From November 2013 to July 2014, officials apprehended 143 individuals listed on the US terror watch list trying to cross the Mexico border and enter the US illegally, according to a confidential Texas Department of Public Safety report obtained by the Houston Chronicle.

And last summer, the US military’s Southern Command warned in an intelligence report that Muslim extremists were using existing migrant smuggling rings in Latin America to gain entry to the US across the Mexico border, according to an account in the Washington Free Beacon.

The Obama administration and its supporters have consistently sought to downplay the threat of terrorists crossing the Mexican border. They say the border is secure and that the threat of terrorists crossing illegally from Mexico is overstated.

No terror plot carried out in the US homeland has involved personnel or material transported across the US-Mexico border.

But to some, that is small comfort.

Conservatives' concerns

During a congressional hearing in September, House Homeland Security Committee Chairman Michael McCaul (R) of Texas asked senior border enforcement officials in the Obama administration whether ISIS might try to smuggle a nuclear device across the Mexico border.

“That’s them in their own words,” Representative McCaul noted, referring to the ISIS magazine article. “I have to take that seriously.”

Kevin McAleenan, deputy commissioner of US Customs and Border Protection, told the committee the government monitors such threats closely.

“We’ve seen aspirational discussions,” he said, acknowledging the claims in the ISIS magazine article. But he added that US officials and their counterparts in Mexico were “not seeing a ton of credible, validated intelligence that suggests that ISIS is trying to exploit specific routes [into the US].”

Evan Vucci/AP/File Rep. Michael McCaul waits for an elevator after arriving in the lobby of Trump Tower in New York in November.

Mr. McAleenan’s response is consistent with the claim consistently advanced by the Obama administration – that the border is secure. But now, with Donald Trump’s election, that narrative and the US approach to border security is about to change dramatically.

Mr. Trump made border security a cornerstone of his campaign for the White House. He says securing the border will be one of his first and highest priorities when he takes office on Jan. 20, including fulfilling his pledge to build a wall on the US-Mexico border.

But it isn’t just about building a wall.

The new administration is poised to pursue an unapologetic version of America-first nationalism, including aggressive enforcement of US sovereign power to decide who enters the country and under what circumstances.

By many accounts, the Trump administration faces a daunting task.

The men behind Trump's pivot

An analysis of border security, together with interviews conducted along the border from Texas to Arizona, paint a picture of vulnerabilities with potentially dire consequences.

Of course, the boundary with Mexico isn’t the only way to sneak into the country. There are more than 95,000 miles of open shoreline and a long border with Canada.

But some security specialists believe smuggling routes from Mexico, including those run by Mexican criminal cartels, offer an established and relatively secure method of entry for would-be terrorists.

Among them is retired Lt. Gen. Michael Flynn, the former director of the Defense Intelligence Agency tapped to become Trump’s national security adviser.

Mr. Flynn told Breitbart News in August that Islamic terror groups and countries that support them are cutting deals with the Mexican cartels for access to smuggling routes into the US. He specifically mentioned Hezbollah, the Lebanon-based Shia Muslim organization aligned with Iran, saying the group has smuggled narcotics and individuals across the border and into the US.

Kathy Willens/AP/File National Security Adviser-designate Michael visits Trump Tower in New York in December.

Another former US official concerned about border security is retired Gen. John Kelly, Trump’s pick as secretary of Homeland Security. Mr. Kelly is the former commander of US Southern Command, which oversees Pentagon operations in South America, Central America, and the Caribbean.

“I believe we are overlooking a significant security threat,” he told senators during congressional testimony in 2015. He said transnational organized crime groups such as the Mexican cartels “could unwittingly, or even wittingly, facilitate the movement of terrorist operatives or weapons of mass destruction toward our borders.”

Kelly warned that such movements would be “potentially undetected and almost completely unrestricted.”

Kelly emphasized that he’d seen no indication of cooperation between the Mexican cartels and Islamic terrorists. But he said it was a major concern.

The current leader of Southern Command, Adm. Kurt Tidd, echoed Kelly’s concern.

“Many people are quick to dismiss the possibility of these groups working together in this part of the world. They believe the absence of evidence of a relationship is evidence of its absence,” he told senators last year.

“Mr. Chairman, we at US Southern Command can’t be that certain,” Admiral Tidd said.

Gauging the threat

The US government takes extraordinary measures to prevent would-be terrorists from entering the country through an airport or other official port of entry.

Each of the roughly 2 million individuals who submit visa applications are vetted as potential security risks. Of the 8,600 who were rejected for security reasons in a recent year, some 2,200 refusals were based on a known or suspected connection to a terror group, according to US Immigration and Customs Enforcement.

In addition, the Transportation Security Administration (TSA) uses a terrorism targeting center to vet each passenger on every incoming flight to the US from overseas. In the first nine months of 2016, nearly 7,000 known or suspected terrorists were denied the ability to board an aircraft or were directed to secondary screening, according to the TSA.

Such comprehensive security efforts stand in contrast to the situation on the southwest border, where large numbers of individuals continue to enter the US without authorization and completely undetected.

Of prime concern are those from 35 so-called “special interest” countries. These are countries where terrorism is an acute problem.

In Fiscal Year 2014, the Border Patrol apprehended 4,585 unauthorized migrants from “special interest” countries, including 66 from Afghanistan, 223 from Iran, 173 from Iraq, 350 from Pakistan, 169 from Somalia, and 61 from Syria, according to the Office of Immigration Statistics.

Many are genuine refugees fleeing war and terrorism. But it can be challenging for US officials to determine their intentions, particularly when significant numbers are crossing the border undetected.

By some estimates, the Border Patrol apprehends roughly 80 percent of those attempting to enter the US without legal authorization. But a 2015 government-funded study disputes that number. The Border Patrol’s catch rate is closer to 54 percent, the study concluded.

If accurate, that would suggest that apart from the 4,585 “special interest” individuals who were apprehended in FY 2014, an additional 3,900 entered the US undetected. Even at the higher 80 percent catch rate, there would still be more than 1,100 undetected border crossers from countries with active terrorist groups.

'Special interest' border-crossers

In the fall of 2015, for example, five Pakistanis and an Afghan were arrested near Patagonia, Ariz., after crossing the border roughly 20 miles to the south. While no links to terrorism were found at the time, a later search of a Federal Bureau of Investigation database revealed that the Afghan had family connections to the Taliban, according to The Washington Times. The Afghan is still in custody. The five Pakistanis sought refugee status and were reportedly released.

A few weeks later, the arrests of five men described as “Middle Eastern” near Amado, Ariz., along a common smuggling route, prompted an investigation by the Arizona attorney general’s office. It revealed a steady flow of money from Middle Easterners to human smuggling rings in Mexico.

Most of the money transfers were sent to individuals in Tapachula, a busy migrant smuggling center in southern Mexico, investigators found. In 2015, one smuggler received 70 money transfers from 69 individuals, all of whom appeared to be of Middle Eastern origin, the investigation revealed.

The attorney general’s office did not link any of the money flows to terrorists, but the activity was seen as evidence of increased movement of money and people from the Middle East to Mexico and potentially across the US border.

Of particular concern to security officials is the potential attempt by ISIS-trained individuals to enter the US undetected.

Estimates are that some 6,000 individuals from western countries have traveled to Syria to join ISIS. Among them are roughly 150 American citizens and residents.

ISIS leaders have said they are inserting trained soldiers of the terror group into the stream of refugees from Syria to establish covert cells in Europe. ISIS members and those inspired by the group have carried out attacks across Europe – including recent mass-casualty atrocities in Berlin, Brussels, Nice, and Paris.

If ISIS soldiers try to return via a US airport or other official port of entry, they risk being photographed, identified, and arrested. Some may try instead to enter the country illegally across the Mexico border where no one will take their photograph or ask for identification, security specialists say.

Warren Richey/The Christian Science Monitor A Border Patrol agent keeps watch along the fence west of Nogales, Ariz.

A growing number of individuals from special interest countries are attempting to cross the border. When they do, Border Patrol agents are instructed to detain them and notify Homeland Security agents or the FBI.

“I personally have arrested maybe a handful every year,” says one long-time Border Patrol agent. “If they are from a special interest country, you get them back [to the Border Patrol office], you take their prints, and 30 minutes later here comes a black SUV,” the agent says, describing the process. “They are loaded up and we never see them again.”

The agent added: “My job is to make sure they don’t enter the country. Once I have arrested them and bring them back here, my job is over.”

Disagreement about training camps

There are also a number of unconfirmed reports of Muslim militants setting up training camps on the Mexican side of the border.

Tim Foley runs a group called Arizona Border Recon in Sasabe, Ariz. The organization conducts armed, civilian patrols near the US-Mexico border. He says he has placed 12 motion-activated cameras near well-traveled smuggling trails leading from Mexico into the US.

Some images, he says, include photos of Afghans, Pakistanis, and Somalis moving north into the US after crossing the border. He adds that his contacts in Mexico tell him a group of 16 Muslim men are living in a compound about three miles south of Sasabe in Mexico.

Gregory Bull/AP/File Tim Foley checks a motion sensing camera he set up along a possible smuggling route during a border surveillance trip in Sasabe, Ariz., on May 11, 2016.

He suggests it is a training facility.

The conservative watchdog group Judicial Watch has also issued a series of reports claiming the existence of terror training camps on the Mexican side of the border.

“An internal Mexican law enforcement report obtained by Judicial Watch confirms that Islamic terrorists have ‘people along the border, principally in Tijuana, Chihuahua, Coahuila, Nuevo León and Tamaulipas,’ ” according to one recent report.

Officials in the Obama administration have routinely denied such reports.

“There are no known international terrorist organizations operating in Mexico,” according to the State Department’s 2015 country report on terrorism.

“Mexican security agencies track open-source reports claiming that terrorist training camps existed in Mexico,” the report says. “In each instance, the media reports have been found to be unsubstantiated.”

Crossing the border undetected

Just catching illegal border-crossers walking into the US can be hard enough. In the ISIS magazine article, smugglers transport a nuclear device across the US border through a tunnel.

More than 200 smuggling tunnels have been discovered along the border in various stages of construction, according to the Border Patrol. The vast majority – 120 so far – have been discovered in Nogales, Ariz.

“One of these days the whole city is going to drop 15 feet because there are so many tunnels,” jokes Border Patrol Agent Felipe Jimenez.

Mexico's Attorney General's Office/AP/File This frame grab taken from a video provided by the Mexican attorney general's office on Dec. 12, 2016, shows one of two tunnels found in the border city of Tijuana that lead into California. The attorney general’s office said the tunnels were apparently used by the Sinaloa drug cartel.

But not everyone thinks a tunnel is necessary. In 2004, a member of a group urging tighter border controls conducted an experiment to make a dramatic point about border security.

A member of the group – a former US Army sniper – carried a simulated nuclear device in a backpack a few steps over the Mexican border at the San Pedro River. He then turned around and walked four miles into Arizona along an active smuggling route to a pickup point near the bridge at Highway 92.

“They put the simulated nuclear bomb in the back of a truck that had actually been used by drug smugglers and drove it to Tucson where it was parked near the front door of the federal building,” says Glenn Spencer, whose group, American Border Patrol, sponsored the effort.

The experiment was recorded on video tape. The grainy images can still be viewed on American Border Patrol’s website.

At no point were they stopped, questioned, or seen.

“We had two TV stations ask us how we did it, so we went back down to the border – with the TV cameras – and showed them how he came across,” Mr. Spencer says. The entire procedure was repeated and recorded.

Afterward, Spencer says he asked: “Did you notice that we just did it again?”

Security steps being taken

News of the “smuggling” operation helped refine Border Patrol tactics. Spencer says his “smugglers” monitored the agent’s radio transmissions to avoid being intercepted. Today, the agents scramble their transmissions, he says.

There have been other changes. In 2004, there were 9,500 Border Patrol agents on the southwest border. Today there are 17,500. In 2006, Congress authorized construction of 700 miles of fencing along the border.

In addition, the US has taken steps specifically to address the threat of nuclear smuggling.

Since 1995, Customs and Border Protection has spent more than $2.5 billion setting up a radiation detection capability at all official points of entry into the US, according to congressional testimony.

The detection technology includes radiation isotope identification devices and personal radiation detectors that are about the size of a pager and are designed to be carried by Border Patrol agents.

Using this equipment, officials can scan nearly all of the mail and parcels, nearly 100 percent of the truck cargo, 100 percent of private vehicles arriving from Canada and Mexico, and 99 percent of cargo containers arriving by sea, according to government officials.

In addition, detection efforts don’t just take place on US soil. Some 60 foreign ports are equipped to conduct pre-departure nuclear screening of cargo headed to the US. As a result, 80 percent of cargo entering an American port has already been prescreened in a foreign country.

Andy Nelson/The Christian Science Monitor/File A Customs and Border Protection officer uses a handheld radiation detection device to check cargo that triggered alarms at the Port of Entry in Blaine, Washington, on June 19, 2006.

But even at official US ports of entry, the screening methods aren’t foolproof. Between 2006 and 2013, the government conducted 144 covert operations designed to replicate an attempt to smuggle a nuclear device into the US at 85 points of entry.

The results are classified, but it is clear that some of the facilities did not perform as intended.

“The results showed differences in the rates of success for interdicting smuggled nuclear and radiological materials across facility types,” according to an October 2015 report by the General Accounting Office.

What such covert tests at official ports of entry can’t identify is the potential success of a nuclear device being smuggled through a tunnel or in a backpack carried across a remote section of the border.

Such a device might be detected later at a Border Patrol highway checkpoint. Or if the smugglers are apprehended in a remote area, an agent’s hand-held detection device might alert her to the presence of nuclear or radiological material.

But the San Pedro River route taken by American Border Patrol in 2004 is still described as wide open by local residents.

“I have been there dozens of times and rarely is an agent watching this quarter-mile area which almost never has water running through it,” Arizona cattle rancher Peggy Davis said in testimony to Congress in September. “Anyone can simply walk in.”