Early one June afternoon, Cody Wilson, a bearded 27-year-old wearing khakis and a pink shirt, walks into the office of a dusty gun range on the outskirts of Liberty Hill, Texas and casually greets the clerk, a tall man with a ball cap, a salt-and-pepper goatee and a rawhide tan. Hanging overhead is a sign with an image of a pistol and the warning that, in case of robbery, the police will not be involved. Another reads GUARDED THREE NIGHTS A WEEK, YOU GUESS WHICH. There’s also a plaque with a quote frequently and falsely attributed to Abraham Lincoln (clergyman William J.H. Boetcker actually said it in 1916): “You cannot strengthen the weak by weakening the strong.” It’s a statement Wilson would disagree with. The clerk asks how business is going.

It’s going well, Wilson explains: His latest product, the Ghost Gunner, is a $1,500 machine that helps anyone with basic technical know-how to build an unlimited number of untraceable assault rifles, regardless of criminal record or mental-health status. He has shipped about 300 so far and has received orders for 700 more. “I’m suing Obama too,” he says. The clerk has been following the story in the news, but the store’s lone customer, a squat man with a white handlebar mustache, is caught off guard.

A worker tests the electric circuit of an Armatix iP1 pistol at the company’s headquarters in Germany.

“He’s the one who started, pretty much, the 3-D printing for guns,” the clerk explains. The customer recognizes him: Cody Wilson, radical libertarian, crypto-anarchist and one of Wired magazine’s 15 most dangerous people in the world. Two years before, when Wilson released online the digital blueprints for the Liberator, the world’s first 3-D-printed gun, the State Department threatened him with prosecution for arms exporting. In May, Wilson filed a lawsuit arguing that, as digital code, the blueprints constitute speech protected by the First Amendment, beyond the censure of federal authorities. “I finally get to sue the feds because they overplayed their hand,” he says, smiling.

The man with the mustache nods supportively, clearly impressed. “Well, hopefully something comes of that,” he says.

The range is closed, but Wilson has driven all the way from Austin expecting to be an exception. When he asks if he can at least pay a range fee, the clerk tells him it’s on the house.

Wilson walks out to the parking lot and stops at his car, an ancient BMW with a crumpled hood. He kicks off his Bearpaw slippers and changes them for a pair of black steel-toed work boots, tucking the cuffs of his chinos inside. “Yep, those are some good old boys in there,” he says. They like him, but that’s not a unanimous opinion here. “Half of the red-staters, man, are full-on for this security state,” he says. “They love the professional culture of the military and police.” Wilson’s efforts to put a gun into the hands of anyone who wants one have made him a hero in some pro-gun circles, a pariah in others. But he’s more than comfortable on the fringe. The last time he was here, one of the rifle line coaches, a Vietnam vet, told him his time on the range was up. By Wilson’s watch he still had two minutes left. So he refused. “He threw his truck in reverse and tried to run me over to intimidate me,” Wilson tells me. “He didn’t like that I was completely comfortable telling him to fuck off.”

At one end of the range an old-timer sits at a firing bench, cradling what looks to be a .50-caliber rifle fitted with a scope. Intermittently, a fiery, thunderous boom! bellows from its muzzle. Wilson walks to the middle of the line and sets down his gear. Beneath his feet a sea of spent brass casings carpets the floor.

Downrange the land slopes gently up into a dusty plain speckled with green, the legacy of devastating floods that washed across Texas just a few weeks before. The middle ground consists of four berms at various distances. The farthest, a thousand yards away, contains a line of red targets that are barely visible without optical aids.

Wilson takes out a plastic bag and starts to assemble a trigger mechanism, building it around a $60 piece of aluminum called a lower receiver. A gun has many parts, but the only part on which the federal government stamps a serial number—“the gun,” in legal terms—is this frame, around which the other parts of an assault rifle are built. As with the rest of the parts, any amateur gunsmith can buy a nearly finished (and unregistered) receiver, then drill a few strategically placed holes to build an untraceable weapon. What Wilson’s latest product—a computer-numerical-controlled milling device called the Ghost Gunner—does is put this ability in the hands of even the most unskilled novice. Earlier in the day, he used a Ghost Gunner to finish this lower receiver, simply clicking through a set of instructions that told him when to shift the receiver’s position, tighten or loosen a bolt and change the drill bit. It took about two hours in all.

The result’s only flaw is one imprecisely drilled hole that now leaves the safety catch spinning loosely in its orbit. But then Wilson finds a bigger problem. Rather than build out a whole new gun, he brought along his Colt AR-15, hoping to substitute the newly machined lower receiver for the stock part in his expensive store-bought rifle. Now he realizes the manufacturer has precluded that with a screw ring. The ring is a good thing, says Wilson—it is intended to keep the stock from loosening after repeated use—but still, someone else has made the decision for him. He bridles at that fact. “With Colt,” he says, “I guess you pay for not getting to do what you want with your rifle.”

The offices for Wilson’s nonprofit, Defense Distributed, are situated in an Austin business park. The interior resembles a Mac repair facility more than a gun shop, with a full-time staff of eight and two part-timers, most of them vegetarians in their mid- to late 20s: Wilson describes them as “suffering, overeducated millennials” who subscribe to his twist on Google’s motto: Think evil. One leads the Alliance of Austin Agorists—a “counter-economic libertarian strategy” that seeks to completely evade the formal economy. (Wilson tried to hire a few of this employee’s Agorist buddies, but “they’re not made for working.”) Wilson also stole an engineer away from National Instruments. Everyone makes at least $15 an hour, the software engineers a lot more.

Cody Wilson and the 3-D-printed Liberator.

For all his varied philosophical influences, Wilson’s roots are pure red state. He grew up in Arkansas, where his father, a Baptist minister, had a law practice—asset protection, estate planning, elder law, end-of-life planning. “Idyllic stuff, no complaints at all,” he says. His father owned a shotgun and a handgun, but Wilson never considered himself a gun guy; in Arkansas, he says, there’s an age when young men start wearing too much camouflage and embracing their fathers’ masculine ideals. That never appealed to him.

But there were traces of what would become his trademark brand of provocative entrepreneurialism—selling candy in competition with approved school fundraisers and pocketing the money, or selling the answers to tests from digital material he discovered his teacher was using. In 2011 he started law school at the University of Texas because it “seemed like the only credible path to any type of money, any type of power.” During his first semester, in the wake of the Citizens United ruling, he formed his own super PAC to help bring down U.S. Senator Mark Pryor. He describes it as an attempt to “gain cachet with the Arkansas machine” and to put political theory into practice. In the end he decided to take his career in a different direction because his politics have “always been antistate.” He spent that summer hanging out with his college buddy Ben Denio and became obsessed with the digital fabrication of guns.

Denio was a radical environmentalist and anarchist. He left the impression of someone “just looking for reasons to blow something up.” He was also obsessed with military history and the sort of “gun nerdisms” that bored Wilson, who was more fascinated by the idea of the gun as “the implement of political realism.” He became obsessed with a singular question: What would be the equivalent of WikiLeaks for guns? The outgrowth of that notion was the Liberator.

The blueprints for the Liberator were computer-aided-design files, essentially computer code. In May 2013, four days after Wilson posted them, he received a letter from the State Department warning that he may have violated ITAR, or International Traffic in Arms Regulations, which govern the ability of anyone in the U.S. to export defense articles. Violations could result in jail time and million-dollar fines. While the State Department considered whether it would require Wilson to get a license to disseminate the code, it demanded he pull the CAD files from his online server. He complied. (By that time, however, the files had already been downloaded more than 100,000 times; they remain widely available on the internet today.)

In May 2015, Wilson and the Second Amendment Foundation filed his lawsuit, which names John Kerry and other State Department officials and seeks not only damages but an injunction against the State Department’s ability to censor Defense Distributed’s files. If granted, it would mean he could immediately publish a trove of new firearm blueprints developed over the past two years.

Wilson summarizes an e-mail from his legal team: In the face of his lawsuit, the State Department is effectively “doubling down,” continuing to require its prior authorization for posting any technical data related to the production or maintenance of a “defense article.” Defined in “perfectly Kafkaesque” terms, as Wilson explains it, “a defense article is any article that is implicated in defense, basically. It has this very circular definition. It gives them infinite discretion.” The regulations also define technical data broadly: “A diagram, a model, a formula, a table, design specification, CAD files—so that’s for yours truly,” he says.

The lawsuit raises complex arguments involving the First, Second and Fifth Amendments. The suit’s central premise revives a legal argument made in the 1990s after the Department of Justice began to investigate cryptographers who were sharing powerful encryption tools online, which the government considered military munitions. In this argument, code—whether it conveys knowledge about how to protect communications or how to build a firearm—constitutes speech protected by the First Amendment, and ITAR imposes an unconstitutional “prior restraint” on that speech. Legal scholars have called Wilson’s suit a novel and unsettled argument for the digital age, as technologies such as 3-D printing continue to blur the difference between a thing and instructions on how to make it, and the internet serves as a means of instant worldwide distribution.

Which is precisely Wilson’s aim: to push back at what he considers the government’s totalitarian impulse to exert control over all new technologies. Aided by technology, he hopes the spread of digital contraband—whether CAD files shared on sites too numerous to prosecute or drug sales, facilitated by Dark Wallet and its copycats, too inscrutable to monitor—will render the rules practically impossible to enforce and the law essentially irrelevant.

Wilson’s political philosophy of free-market anarchy can be hard to triangulate. He enjoys using leftist critical theory in service of what he (jokingly) calls his brand of “proto-fascistic-anarcho-republicanism or something.”

When Wilson came up with the idea for the Ghost Gunner, his father told him he might sell five or 10. But Wilson thought he could squeeze at least $2 million out of the idea. (With roughly 1,000 orders at $1,500 each, he’s close to proving himself right.) A self-described “hype man,” Wilson is a savvy promoter. Wired just went live with a glowing review of the Ghost Gunner, and he has already received a couple of new orders. On his laptop he clicks through e-mail lists he’ll use to publicize the story. On this Listserv, he says, he has about 4,000 people—his total database, split across seven constituencies, is about 20,000, halfway to “a list you can live on,” as he’s learned from targeted-ad consultants—and he’s hoping to convert one to two percent of them into sales. He also keeps an extensive press list, categorized by the likelihood of favorable coverage.

He describes the Ghost Gunner as both a gift to his red-state base and an example of shrewd but cynical capitalism, preying on the insecurities of clients who will likely never use his product but feel empowered by the very prospect of doing so. He describes his ultimate goal in metaphysical terms. “It’s black magic to these people when they see this thing running. They don’t understand it. They think there’s some spirit in it that was banished and that they thought they had gotten rid of,” he says. “It’s about becoming a partisan for this other, deeper, mysterious aspect of the world.”

For every worldview that endorses a new technology there is a diametrically opposed worldview that endorses its opposite. If Wilson’s work puts the power to decide life and death into countless unknown hands, the smart gun puts it into fewer.

The quest for a smarter gun can be traced to 1886, after D.B. Wesson, a founding partner of Smith & Wesson, learned that a child had been injured playing with one of his company’s products. Wesson asked his son to design a childproof handgun: a revolver with a metal lever on the back that had to be depressed as the trigger was pulled in order to fire. Until 1940, when the technology was abandoned, the company sold more than half a million such guns.

A prototype of the Armatix iP1 smart gun.

Today, with roughly 30,000 Americans killed by gunfire every year, many argue that smart-gun technology, which restricts a gun’s use to its proper owner, could prevent accidental shootings and gun theft, as well as protect police officers from criminals using their own guns against them. But personalization technology has long faced resistance. In 1976 the pro-gun lobby pressured Congress to prevent the Consumer Product Safety Commission from overseeing guns the way it does other consumer products (such as childproof medicine bottles).

In 2000 Bill Clinton announced grants of $300,000 to Smith & Wesson and F.N. Manufacturing Inc. to spur the technology. A subsequent boycott of Smith & Wesson “sent fear into the hearts of gun manufacturers that, should they break ranks and start to make safer guns, they could be severely punished,” says Stephen Teret, the founding director of the Center for Gun Policy and Research at Johns Hopkins University. Consequently, most smart-gun technology has come from Western Europe.

Teret points to one study that concluded smart-gun tech could have prevented 37 percent of accidental shooting deaths. It could also presumably make a significant dent in crimes committed with some of the estimated 250,000 to 300,000 guns stolen from homes each year. How many lost lives does that translate to? “That’s a sound question for which we should have an answer,” he says. “We lack data. The reason we lack data is politics.” The United States should collect data on gun fatalities just as it does on auto fatalities to craft better preventive policies, he says, but in the past few years, the NRA has used its influence in Congress to repeatedly curtail funding for research by the Centers for Disease Control and Prevention that would have gathered that information.

For those who saw gun deaths as a public health crisis, there was hope they could force gun manufacturers to incorporate smart-gun tech through litigation, just as car companies had been pressured to offer air bags amid a congressional stalemate on the issue. “That’s why the National Rifle Association came up with the idea of getting Congress to give them immunity from liability,” says Teret. In 2005, president George W. Bush signed the Protection of Lawful Commerce in Arms Act, giving gun makers far-reaching immunity from liability litigation. The NRA’s fingerprints were “all over this. There’s no question this was their doing. They got Congress to agree that gun manufacturers could not be sued for damage done to people by guns, except under highly restricted circumstances,” Teret says. “No other manufacturer has immunity from liability for damages caused by its product if the product was made in a way that was less safe than it could be.”

Nineteen years ago, Teret helped draft a New Jersey law that would require all guns sold in the state to use smart-gun technology within three years of the first smart gun becoming available anywhere in the United States. The leading contender to do so has been the iP1, a .22-caliber pistol designed by the German arms manufacturer Armatix. The gun is paired with a wristwatch activated by a five-digit PIN and must be within 10 inches of the watch to fire. But after the company announced plans to begin selling the gun in California, its U.S. representative, Belinda Padilla, faced a wave of harassment: Her name and phone number and a photo of the location of her post office box were posted on an online gun-enthusiast forum, and she began to get menacing calls. Padilla reportedly had an agreement with the owner of a California gun club to sell the iP1. But after the club’s owner, James Mitchell, told The Washington Post the gun would revolutionize the industry, a wave of social-media threats to boycott the club killed the deal.

“They tried to put the product on the market, and the market reacted,” Lawrence G. Keane of the National Shooting Sports Foundation told The New York Times. But Dr. Garen Wintemute, head of the Violence Prevention Research Program at the University of California, Davis school of medicine, takes issue with that characterization. “A small vocal group acted to intimidate a single store that was bringing a new product to the market,” he says. “That’s not the market speaking. That’s tyranny.”

In the wake of the Sandy Hook shooting, President Barack Obama declared an executive order to spur support for smart-gun research. Silicon Valley entrepreneur Ron Conway, an initial investor in everything from Google to Facebook, offered $1 million in prize money for the development of what he described as “the iPhone of guns.” The race to build that is global. Ireland-based TriggerSmart teamed with researchers at the Georgia Tech Research Institute in Ireland to develop a prototype gun that can be fired only when in the presence of an RFID-equipped ring or bracelet. The company hopes to create the ability to remotely disable guns in airports, schools and other areas. California company Yardarm has created a gun that can be remotely tracked and disengaged by the owner via an app or a website. The technology can even alert the owner if the weapon is moved by an unauthorized individual.

Critics argue smart technology could malfunction just when a gun is needed most. They point to the New Jersey statute as an example of how the technology could further the gun-control agenda, resulting in a ban on all nonsmart guns.

“I think part of the appeal of guns in general is that they’re not smart,” says gun-industry analyst Andrea James. “Key to some of the appeal of firearms themselves is the sense of freedom they give you. When you pull the trigger, if there’s a bullet in the chamber, the bullet comes out. You start putting in an RFID chip, then all of a sudden, whether or not a bullet comes out, it’s controlled by something other than your finger. And if that can be controlled on a micro level, it can be controlled on a macro level.”

The only objections to smart guns come from “Luddites who are afraid of any new technology,” says Teret. “It would be wrong to say these guns will be 100 percent reliable.” But they will be more reliable than the status quo. “If you introduce electronics into the products, the products are going to be more reliable. That has been the trend with all products for many decades. What’s remarkable is that guns are still made the way they were made more than a century ago.”

The Armatix iP1 eventually found a home at a gun store in Nebraska, which should have started the three-year time clock for all guns sold in New Jersey to incorporate the technology. But the state’s attorney general issued a report denying that the iP1 meets the statutory definition of a smart gun. Teret calls the attorney general’s reasoning “squirrelly” and says it violates the legislation’s intent. A bill similar to New Jersey’s has stalled in the California State Assembly.

For Wilson’s part, he sees legislation around smart guns, like legislation mandating emissions standards for smart cars, as “a political contrivance,” gun control masquerading as gun safety. “You’re forcing your own vision of the future,” he says. “They’re not willing to say they want to take it away from you, but they kind of look with turned-up lips and use market language. Just have an ideology if you’re going to have one. Tell me what you want.”

When I press him on whether he thinks technology will inevitably put a gun in the hands of anyone who wants one, he concedes that it is in part a strategic posture. “I’m trying to rep that position when I’m in front of the enemy. Do I really believe that? No, I don’t think I’m convinced of this. But I’m trying to be the monster or the mascot for that idea.” For Wilson, liberty is the highest principle and the ultimate end. “Why isn’t liberty the default position?”

Wilson’s bullish posture naturally invites the question of how far he thinks things should be allowed to go. After the release of the Liberator, a libertarian writer friend of mine, Conor Friedersdorf, penned a piece for The Orange County Register in which he voiced hope that the democratization of technology would hinder tyrants and strengthen individual rights, but he also feared it would put weapons more powerful than guns “in the hands of evil people more cheaply and easily than ever before.”

I put one of Friedersdorf’s questions to Wilson: If a chemistry set allowed anyone to make a contagious virus with the capacity to kill millions, should it be outlawed and suppressed? Wilson looks at it in context. Since 9/11 the Department of Justice has “locked down all of the chemical industry,” he says. “You can’t just go buy supplies. You get reported on. Everybody’s an agent of the court.” He compares it to another question he is frequently asked: If you can 3-D print a gun, why shouldn’t we 3-D print a nuclear weapon? “It’s not the same thing as carving a hole in a piece of metal like we’re doing with our little machine.” But hold his feet to the fire, and on principle, his answer is that neither technology should be suppressed by the state. “The liberty interest should always prevail,” he says.

It’s National Gun Violence Awareness Day, he says, showing me a photo of Jason Bateman wearing orange. But he sneers at the idea that celebrity activism can stop the coming anarchy.

“Biohacking by computers should happen; people should be able to experiment. Terrible things are coming,” he says. “People are going to play with whatever future is saved. Kids are going to be able to experiment with gene sequences, and it will be terrifying. I’m sorry, it’s just where it’s going.”

He’s comfortable with his own contradictions.

“All the power in this gun thing is: Look at what I’m able to evoke. I’m able to rattle the chain—back to people’s deepest feelings about what America was supposed to be, about where history was supposed to go and what patriotism is and what it means to be a free man. I’m able to do that just with this one little object.”