The country’s government has consistently looked to China, its largest trading partner and ideological ally, for techniques for controlling the online activity of its citizens.