In the part of Baltimore hardest hit by the recent riots and arson, more than a third of families live in poverty, median income is $24,000, the unemployment rate is over 50%, some areas burnt out in the riots of 1968 have never been rebuilt, incarceration rates are sky high, 33% of the homes are vacant (thanks to an ongoing foreclosure crisis), and water service is being shut off for people who can’t afford to pay rising water rates. Residents, mainly black, live in what is really an unofficially segregated, hollowed-out Rust Belt city that just happens to be located on the East Coast.

As Max Blumenthal pointed out when the city’s mayor started denouncing “outside agitators,” more than 70% of Baltimore’s police force lives beyond the city limits, at least 10% of them out-of-state. The Baltimore PD is also notorious for its brutality, for the numbers of (black) residents it seems to gun down, and for its give-not-an-inch “broken windows” policing policies. In a city that is 62% black and 28% white, police officers are still 46% white and 80% outsiders heading into neighborhoods that are almost totally black. Unlike the residents of such neighborhoods, Baltimore’s police lack for little. Thanks in part to Pentagon and other government programs, the force is armed to the teeth in the increasingly military fashion that has become the post-9/11 state of things (and that TomDispatch has been covering since 2004.) It acts as if it were, that is, an occupying army, not a neighborhood protector. In this sense, “community policing” is now a joke in the U.S.

When the CVS stores go up in flames and local stores are looted, politicians denounce what’s happened and demand an instant return to law and order, while calling on police departments to wear body cameras and rethink their attitudes. But there’s another reality that has to be faced. Give some credit to Hillary Clinton. In her recent speech on the police killings of black men from Ferguson to Baltimore, she included this single on-the-mark sentence: “We can start [building on what works] by making sure that federal funds for state and local law enforcement are used to bolster best practices, rather than to buy weapons of war that have no place on our streets.” Put another way, you can’t arm and militarize the police, as both the Pentagon and the Department of Homeland Security have been doing since 9/11, and send them into impoverished communities as if for war, sporting a mind-set from the global war on terror, without getting what you’ve functionally wished for. In a sense, in the arms race that is America today, you might say that you are what you “carry.”

Among the illusions of our age, there’s this: the idea that the U.S. can fight wars in whatever fashion it pleases, year after year, in distant lands without changing our society as well. In fact, those wars have been coming home for a long time in myriad ways, and never more obviously than with American police forces and their practices. It’s not just that the police (and SWAT units) are now filled with vets from the war on terror, or that they are armed with weaponry directly off its battlefields, but that the mentality that has made those wars such disasters has come home with the troops and weaponry.

As Michael Gould-Wartofsky, author of the new book The Occupiers: The Making of the 99 Percent Movement, suggests, thoroughly militarized, surveillance-heavy forces are bringing counterinsurgency thinking from Iraq and Afghanistan back to this country. The record of such thinking abroad brings to mind a question first raised by State Department whistleblower Peter Van Buren about Washington’s new war in Iraq: What could possibly go wrong? Tom

Last week, as Baltimore braced for renewed protests over the death of Freddie Gray , the Baltimore Police Department (BPD) prepared for battle. With state-of-the-art surveillance of local teenagers’ Twitter feeds, law enforcement had learned that a group of high school students was planning to march on the Mondawmin Mall. In response, the BPD did what any self-respecting police department in post-9/11 America would do: it declared war on the protesters.

Over the course of 24 hours, which would see economically devastated parts of Baltimore erupt in open rebellion, city and state police would deploy everything from a drone and a “military counter attack vehicle” known as a Bearcat to SWAT teams armed with assault rifles, shotguns loaded with lead pellets, barricade projectiles filled with tear gas, and military-style smoke grenades. The BPD also came equipped with “Hailstorm” or “Stingray” technology, developed in America’s distant war zones to conduct wireless surveillance of enemy communications. This would allow officers to force cell phones to connect to it, to collect mobile data, and to jam cell signals within a one-mile radius.

“Up and down the East Coast since 9/11, our region has armed itself for that type of emergency,” said Baltimore Mayor Stephanie Rawlings-Blake. She was defending her police department’s acquisition of this type of military technology under the Department of Defense’s now infamous 1033 Program. It sends used weaponry and other equipment from the battlefields of the country’s global war on terror directly to local police departments across the country. “But it’s very unusual,” Mayor Rawlings-Blake added, “that it would be used against your own citizens.”

It is, in fact, no longer unusual but predictable for peacefully protesting citizens to face military-grade weaponry and paramilitary-style tactics, as the counterinsurgency school of protest policing has become the new normal in our homeland security state. Its techniques and technologies have come a long way in the years since Occupy Wall Street (and even in the months since the first protests kicked off in response to the killing of Michael Brown in Ferguson, Missouri). Here, then, is a step-by-step guide, based on the latest developments in the security sector, on how to police a protest movement in the new age of domestic counterinsurgency.

1. Equate Dissidents With Domestic Terrorists.

Since 2012, law enforcement and intelligence agencies have repeatedly sought to link street activism with domestic terrorism and radical activists to “violent extremists.” For instance, one memo from the Department of Homeland Security (DHS) Office of Intelligence and Analysis attempted to tie events in Ferguson last year to recruitment efforts by the Islamic State in Iraq and Syria (ISIS): “Although at this time, violence in Ferguson has largely subsided... radical Islamists [have] used social media to urge others... to conduct Jihad.” A separate arm of DHS, the Threat Management Division, issued an ominous warning around the same time:

“Currently there is no indication that protests are expected to become violent. However, current civil unrest associated with the incident in Ferguson, MO, presents the potential for civil disobedience... Absent a specific actionable threat, you should refer to the list of suspicious activity indicators in identifying and mitigating threats. Some of these behavioral indicators may be constitutionally protected activities.”

Earlier this year, amid the fallout from the refusal of a grand jury to indict a police officer in the Eric Garner “chokehold” death, New York City Police Department (NYPD) Commissioner Bill Bratton proposed the creation of a new special ops unit he called the Strategic Response Group. It was to be “designed for dealing with events like our recent protests, or incidents like Mumbai or what just happened in Paris.” The group would be “equipped and trained in ways that our normal patrol officers are not,” and outfitted “with the long rifles and machine guns.” Though Bratton, facing a public outcry, later walked his statement back, his conflation of events involving unarmed protesters and armed militants was clearly no coincidence.

In recent years, the war on dissent has hit ever closer to home, with police departments importing some of the practices first pioneered in counterterrorism operations overseas.

One of these is the use of “black sites” for the temporary disappearance and detention of political dissidents. Anti-war activists learned this lesson firsthand during May 2012 protests against the North American Treaty Organization (NATO) Summit in Chicago, when nine demonstrators were arrested by the police and transported to a warehouse in Homan Square. Three would be held incommunicado for nearly 24 hours, shackled to a bench and kept in a wire cage before being charged with material support for terrorism, conspiracy to commit terrorism, and possession of incendiary devices -- devices constructed with the assistance of undercover officers in what turned out to be an elaborate act of entrapment in the run-up to the NATO Summit.

2. Arm the Police With “Less-Lethal” Weapons (Which Can Actually Create More Lethal Situations).

Under the 1033 Program, more than 460,000 pieces of “controlled property” -- that is, military-grade weaponry and other equipment -- have been transferred from the Pentagon to local police departments since 1997. That includes 92,442 small arms, 44,275 night-vision devices, 5,235 light armored cars, 617 tank-like vehicles, and some 616 aircraft. More than 78,000 such transfers were reported for 2013 alone. As the White House admitted in a recent report, programs like 1033 “do not necessarily foster or require civil rights/civil liberties training,” and “generally lack mechanisms to hold [law enforcement] accountable for the misuse or misapplication of equipment.”

The DHS has an even more expansive mandate to deliver the militarized goods to local law enforcement by way of its Homeland Security Grant Program (HSGP). In 2014 alone, the HSGP gave out over $1 billion in grant funding, with special provisions for “high-threat, high-density urban areas.” The list of DHS-authorized equipment provided to local police departments includes everything from Bearcats and helicopters to battle dress uniforms, body armor, ballistic helmets, and shields. Other agencies, like the Bureau of Justice Assistance (the funding arm of the Department of Justice), dole out hundreds of millions of dollars annually to police departments -- about 10% of which goes toward controlled equipment like armored vehicles, explosive devices, firearms, and “less-lethal” weapons like tear gas and TASERs.

This scenario has made for some lucrative investment opportunities. In the wake of the Baltimore riots, TASER International has seen its stock price spike. One market report noted that as “unrest spreads [and] as these issues continue to boil to the surface, investors are betting that will lead to more sales and profits.” After all, the market for less-lethal weapons alone is expected to more than double in the next five years, while the broader market for what are now called “homeland security products” is projected to grow to more than $107 billion by the year 2020.

Today, private arms developers are perfecting a new generation of “less-lethal” weapons: that is, weapons designed to incapacitate their targets but with a lower likelihood of fatalities. The latest model is known as the “Bozo bullet” for reportedly looking like a clown’s nose, and is currently undergoing its first test run in -- you guessed it -- Ferguson. It would allow the police to repurpose their service weapons at will, docking the “Bozo” on the barrel of a normal handgun to deliver a “less-lethal” payload. But critics argue that, by disarming the ordinary bullet of its psychological impact, such equipment will encourage police officers to reach for their guns more quickly and so serve to make the use of force more likely.

Meanwhile, peace officers in the thick of recent protests seem to be reaching for those guns ever more quickly, no matter how lethal the payload. At a December demonstration in downtown Oakland, California, an undercover officer was, for instance, photographed pointing a pistol at unarmed demonstrators. At a February march in Manhattan, a Port Authority officer was caught on video cocking a shotgun and asking protesters, “Are you scared?” In Los Angeles last summer, an officer with the Federal Protective Service, an agency of the Department of Homeland Security tasked with policing federal government facilities, admitted to actually opening fire with a handgun on a truck full of pro-Palestinian protesters.

3. Wage Wave Warfare.

Long-range acoustic devices (LRADs), also known as “sound cannons,” have been on American streets in times of protest since the Republican National Convention in 2004. Though the machine is capable of transmitting tones that can cause excruciating pain, until recently, its use against civilians had been limited to communicating police orders at a distance. That changed last year, when the LRAD’s “sound deterrent feature” -- originally designed for military use against “enemy combatants” in the Persian Gulf -- was deployed as an “area denial device” against protesters, first in the streets of Ferguson, then in the streets of Manhattan.

The sound cannon works as a form of wave warfare, concentrating and directing acoustic energy at a volume of up to 152 decibels. Even the NYPD’s own Disorder Control Unit has acknowledged that it can “propel piercing sound at higher levels than are considered safe to human ears.” It can also cause those subjected to it permanent hearing damage.

And this is just considered a beginning in what might be thought of as the domestic sensory wars. Novel forms of wave warfare are currently under development by the Pentagon’s Joint Non-Lethal Weapons Program. One such innovation, known as “Active Denial Technology,” works much like a microwave oven -- with the waves directed at the skin of a target to produce an “intolerable heating sensation.” A more portable version of this technology, branded the Assault Intervention System and sold by defense contractor Raytheon, has already been made available for domestic deployment in Los Angeles County.

Another innovation, known as “Skunk,” is a type of stink bomb that has been described by those in the know as an irresistible combination of “dead animal and human excrement.” In response to recent urban uprisings, police departments across the country are reported to be eagerly stockpiling the stuff. “We’ve provided some Skunk for the law enforcement agencies in Ferguson,” says Stephen Rust, program manager at a Maryland-based company that manufactures the malodorant. “I’m going to be able to drill [a target] with a round while I put him in the dirt. I can mark him with Skunk and he will be easy to locate when the crowd disperses.”

4. Replace Humans with Robots and Predictive Technology.

Increasingly, law enforcement is moving to replace human “deterrence” with robotic versions of the same -- remotely piloted aircraft, remotely operated vehicles, and other robotic platforms are to become domestic standbys in support of police surveillance missions and SWAT operations. Such platforms have been deployed, on the ground and in the air domestically, to conduct routine surveillance of protest activity, while in other countries they are already being weaponized with pepper spray and other projectiles.

From 2012 to 2014, the Federal Aviation Administration considered requests from at least 19 police and sheriff’s departments, as well as National Guard units in nine states, to fly drones in domestic airspace. The Los Angeles Police Department (LAPD) recently acquired two Draganflyer X6 drones for use during large protests and other “tactical events.” And while the NYPD has refused to release any documents on its own drone program, officials have stated that they are “supportive of the concept of drones, not only for police but for public safety in general,” and that they are currently looking into “what’s on the market, what’s available.”

Support for such surveillance is on the rise. DHS has made millions of dollars available annually for “forward-looking” police forces to procure the latest robotic systems, along with “software upgrades, engine upgrades, arms, drive systems, range extenders, trailers, etc.” Also included is “surveillance/detection” equipment in which drone technology may be integrated with audiovisual systems and with “optics capable of use in long-range, sometimes long-term, observation."

In recent years, a new frontier has opened up with the advent of “predictive policing” (or “PredPol,” in industry parlance), which aims to use big data and complex algorithms to forecast when and where a crime is likely to be committed, and who might be a likely culprit. The practice started out as a project of the Army Research Office (a centralized science laboratory under the purview of the Pentagon), was converted to civilian use by Bill Bratton during his tenure as commissioner of the LAPD, and has since spread to over 150 departments nationwide.

Take the NYPD. In the immediate aftermath of the Occupy protests, the department entered into an unprecedented partnership with Microsoft to develop a predictive policing technology known as the Domain Awareness System. It “aggregates and analyzes existing public safety data streams in real time,” drawn from thousands of closed-circuit television cameras, license plate readers, and criminal history databases, and is intended to give intelligence analysts “a comprehensive view of potential threats.” Though we don’t yet know the extent to which it has been deployed during protests, we do know that Domain Awareness Systems have been popping up in protest hubs around the country, including Baltimore, Chicago, and Oakland.

5. Make “Friends” and “Follow” People.

Considered “open source intelligence” (or “OSINT”), social media networks like Twitter, Facebook, Instagram, and YouTube have proven veritable gold mines for intelligence analysts attempting to track protest events in real time. They have also provided police detectives with a rationale to question individual protesters about their political activities.

Just last week, we learned that amid the protests in New York City following the acquittal of the officers who killed Eric Garner, at least 11 arrestees were interrogated in this manner prior to their release from police headquarters, including several who were asked explicitly about their online activities on social media sites. As Deputy Commissioner Lawrence Byrne tells it, when detectives started seeing threats on social media, “The Detective Bureau began a process of interviewing defendants arrested during the protests... in an attempt to obtain information about the specific acts... as well as the general threat environment relating to such acts.”

Since 2012, the NYPD’s Intelligence Division has officially encouraged its employees to engage in “catfishing” on social media sites “for investigative or research purposes,” which, with the permission of police brass, may include “investigations involving political activity.” Increasingly, such catfishing has become common practice among police and private security forces nationwide. In Bloomington, Minnesota, for example, intelligence analysts working for the Mall of America’s Risk Assessment and Mitigation unit and in conjunction with members of the local Joint Terrorism Task Force (a collaborative intelligence operation anchored by the FBI) reportedly used fake Facebook accounts to build dossiers on at least 10 area activists. This was ahead of a protest on police accountability (or the lack of it) slated to take place on Mall of America property.

The Department of Homeland Security, for its part, continues to develop its Media Monitoring Capability to impressive effect, “leveraging news stories, media reports and postings on social media sites... for operationally relevant data, information, analysis, and imagery” including “partisan or agenda-driven sites” as well as those that “reflect adversely on DHS.” Many of the nation’s “fusion centers,” set up in the aftermath of 9/11 to encourage collaboration among intelligence agencies, have partnered with social media sites to monitor Occupy-style activism. “Such websites can provide crucial information during civil unrest,” notes Dale Peet, a veteran of Michigan’s statewide fusion center and now an employee of SAS, a private firm that performs social media analytics for the state.

And that’s only a beginning when it comes to social media surveillance. Its future is already being written in the labs of the Intelligence Advanced Research Projects Activity (IARPA), the national intelligence community’s blue-skies research arm. One recent project seeks to match online and offline “behavioral indicators,” including “ideology or worldview.” Another extracts geolocation information from posts, photos, and videos that users might prefer to keep private. Yet another, known as Open Source Indicators, analyzes social media data to “anticipate and/or detect significant societal events, such as political crises [and] riots.” The project’s goal, in the words of its true believers, is ultimately to “beat the news,” giving the government new leverage over alleged enemies of the state.

What we are seeing in the dark corners of cyberspace is of a piece with what we are seeing in the streets of our cities: the leading edge of a new age of domestic counterinsurgency. From black sites to Bearcats, sound cannons to stink bombs, drones to data mining, the component parts of a new police counterinsurgency program are being assembled with remarkable speed. While the basic architecture of this program has been in place ever since 9/11, it is being built up in new and ever more sophisticated ways. The point of all of this: to keep an eye on our posts and tweets, intimidate protesters before they hit the streets, pen them in on those streets, and ensure that they pay a heavy price for exercising their right to assemble and speak. The message is loud and clear in twenty-first-century America: protest at your peril.

Michael Gould-Wartofsky is the author of the new book, The Occupiers: The Making of the 99 Percent Movement (Oxford University Press). He is a PhD candidate in Sociology at New York University. His writing has appeared in the Washington Post, the Nation, Salon, and Jacobin, along with TomDispatch, and his research has been featured on PBS and NPR. To go to his website, click here. Follow him at @mgouldwartofsky.

Follow TomDispatch on Twitter and join us on Facebook. Check out the newest Dispatch Book, Nick Turse’s Tomorrow’s Battlefield: U.S. Proxy Wars and Secret Ops in Africa, and Tom Engelhardt's latest book, Shadow Government: Surveillance, Secret Wars, and a Global Security State in a Single-Superpower World.

Copyright 2015 Michael Gould-Wartofsky