When is a gun not just a gun? When it’s also constitutionally protected free speech.

That is the legal argument being made by Cody Wilson, a Texas man who gained attention two years ago by posting what are believed to be the world’s first online instructions for how to build a 3-D printable gun. Mr. Wilson’s files for what he called the Liberator, a single-shot pistol mostly made of plastic, were partly a statement about freedom in the digital age and partly a provocation — and provoke they did.

A few days after the plans for the Liberator were put online, the State Department ordered Mr. Wilson to remove them, threatening him with jail time and million-dollar fines for having possibly broken rules that govern the export of military data.

Now, with a high-powered legal team behind it, Mr. Wilson’s company, Defense Distributed, has filed suit against the State Department, claiming that its efforts to stop him from publishing his plans, which are no more than computer code, amount to a prior restraint on free speech. The 25-page suit, filed on Wednesday in Federal District Court in Austin, Tex., is an innovative and apparently unprecedented effort to use the First Amendment in support of the Second.

“Defense Distributed believed, and continues to believe, that the United States Constitution guarantees a right to share truthful speech,” the lawsuit states. “Especially speech concerning fundamental constitutional rights in open forums.”