The country had sharp partisan divisions, at that time between John Adams and his Federalist majority in Congress and Thomas Jefferson's Republicans. The Federalists passed laws denying citizenship to immigrants or imposing long waits for naturalization. One of the Alien Acts gave the President the power to deport aliens deemed undesirable -- a provision still on the books and at issue in the travel ban court cases. And the President denounced the angry and often false criticisms of himself and his government and sought to punish his critics.
In that case, his partisan Congress passed the Sedition Act, which said:
That if any person shall write, print, utter, or publish, or shall cause or procure to be written, printed, uttered, or published, or shall knowingly and willingly assist or aid in writing, printing, uttering, or publishing any false, scandalous and malicious writing or writings against the government of the United States, or either House of the Congress of the United States, or the President of the United States, with intent to defame the said government, or either House of the said Congress, or the said President, or to bring them, or either of them, into contempt or disrepute; or to excite against them, or either or any of them, the hatred of the good people of the United States, or to stir up sedition within the United States; or to excite any unlawful combinations therein, for opposing or resisting any law of the United States, or any act of the President of the United States, done in pursuance of any such law, or of the powers in him vested by the Constitution of the United States; or to resist, oppose, or defeat any such law or act; or to aid, encourage or abet any hostile designs of any foreign nation against the United States, their people or government, then such person, being thereof convicted before any court of the United States having jurisdiction thereof, shall be punished by a fine not exceeding two thousand dollars, and by imprisonment not exceeding two years.Nota bene: did you notice that the law did NOT outlaw criticism of the Vice President -- opposition leader Thomas Jefferson?
In fact, as the Berkin book notes, "Only 11 of the 17 men and one woman indicted [under that act] actually went to trial, and most of the editors, released on bail, continued to publish their newspapers in the interim... They had been incarcerated but not silenced." The Sedition Act expired at the end of the Adams administration -- and should stay there.