DUNHUANG, China — An oil-field worker in this Gobi Desert town posted poetry online memorializing the victims of the Tiananmen Square crackdown. An artist in Shanghai uploaded satirical photographs of his wincing visage superimposed on a portrait of the Chinese president. A civil rights lawyer in Beijing wrote microblog posts criticizing the Communist Party’s handling of ethnic tensions.

In each case, the men were detained under a broad new interpretation of an established law that the Chinese authorities are using to carry out the biggest crackdown on Internet speech in many years.

Artists, essayists, lawyers, bloggers and others deemed to be online troublemakers have been hauled into police stations and investigated or imprisoned for “picking quarrels and provoking trouble,” a charge that was once confined to physical activities like handing out fliers or organizing protests.

The increasing use of that law to police online speech, which appears to have become more common in recent months, is a piece of President Xi Jinping’s strategy to deploy the legal code to silence dissent and clamp down on civil society.