The 5,200 troops mobilizing to the U.S. southern border are headed there to deter a caravan of migrants, but some of the direct threats they are preparing for are homegrown, according to documents obtained by Military Times.

In those documents, the military is concerned about the already dangerous drug cartels that operate with impunity on both sides of the border, armed U.S. citizens taking the law into their own hands — or pilfering their gear — and far-right or far-left protesters inciting violence.

The deployment was ordered by President Donald Trump to counter a caravan of thousands of migrants who are traveling primarily by foot and aren’t expected to reach the U.S. border for weeks. The president has ratcheted up the potential threat posed by the caravan, tweeting that the caravan potentially contains terrorists, gang members and other threats.

Our military is being mobilized at the Southern Border. Many more troops coming. We will NOT let these Caravans, which are also made up of some very bad thugs and gang members, into the U.S. Our Border is sacred, must come in legally. TURN AROUND! — Donald J. Trump (@realDonaldTrump) October 31, 2018

The deployment has been questioned for its use of active-duty troops over National Guard forces, who would typically have the border security mission, and for its timing right before the Nov. 6 election.

Defense Secretary Jim Mattis, when questioned on the deployment Wednesday, took issue with the suggestion that it was political.

“We don’t do stunts in this department. thank you,” Mattis told reporters.

This federal law limits what US troops deployed at the border can do The more than 5,200 active-duty troops being sent by President Donald Trump to the U.S.-Mexico border will be limited in what they can do under a federal law that restricts the military from engaging in law enforcement on American soil.

× Fear of missing out? Sign up for the Early Bird Brief - a daily roundup of military and defense news stories from around the globe. Thanks for signing up. By giving us your email, you are opting in to the Early Bird Brief.

In the operations order for the mission, which was obtained by Military Times, U.S. Army North stated that the reason behind the deployment was that the level of violent drug and gang activity and the influx of illegal border crossings had reached crisis levels.

“The security of the United States is imperiled by a drastic surge of illegal drugs, dangerous gang activity and extensive illegal immigration threatens the safety of citizens and undermines the rule of law,” the order states.

In the planning documents that follow, the deploying units are cautioned against homegrown militias roaming along the U.S. southern border and violence incited by extremist groups.

Airman 1st Class Trevor Pearce, a loadmaster with the 3rd Airlift Squadron, briefs passengers aboard a C-17 Globemaster III at Fort Knox, Ky., in support of Operation Faithful Patriot on Oct. 30, 2018. The C-17 aircrew provided strategic airlift to Headquarters Company, 89th Military Police Brigade, which was deploying to the Southwest Border Region to support and enable Department of Homeland Security and other law enforcement agencies as they conduct coordinated efforts to secure our southwest border. (Airman 1st Class Zoe M. Wockenfuss/Air Force)

From the papers, the military is preparing to defend against an “estimated 200 unregulated armed militia members currently operating along the [Southwest Border]. Reported Incidents of unregulated militias stealing National Guard equipment during deployments. They operate under the guise of citizen patrols supporting [Customs and Border Patrol] primarily between [Points of Entry].”

In addition, the planning documents said, “historically, protests occur at the various [Customs and Border Patrol points of entry]” in support of immigrants and, in some incidents, cause closures. Previous protests in support of immigration caravans or enforcement of immigration law have occurred throughout the US. Normally peaceful unless extreme right or left groups attend."

Publicly, the top commander in charge of homeland defense will only say the military does not yet have a full understanding of what threats will surface from the caravan. However, some violent acts that have taken place within the caravan and the way it has forced its way through the border between Guatemala and Mexico has raised concerns that the makeup of the population traveling differs from the past.

“We are working closely with [Customs and Border Patrol] to understand the makeup and the nature of this caravan,” said U.S. Northern Command chief Air Force Gen. Terrence O’Shaughnessy. “This caravan is different than what we’ve seen in the past.”

Mattis, when pressed, has tried to make this deployment of at least 5,200 active duty forces seem like business as usual.

“We are there in support of the secretary of homeland security, who needs additional military assistance. We do this following storms, we do this in support of the Department of Homeland Security. This is a different aspect of it, but that’s what we are doing,” Mattis said Wednesday.