China has sentenced a U.S.-based dissident to five years in prison, following a closed trial in which he was accused of spying for Taiwan and entering China illegally.

Forty-year-old Yang Jianli spent more than two years in prison before a Beijing court sentenced him to five years in prison. He had been tried behind closed doors last August, but proceedings adjourned without a verdict.

Yang Jianli had been a student leader of the 1989 pro-democracy movement in China, which ended with the killing of hundreds of unarmed demonstrators by government troops. He fled China and went to the United States, where he continued his work to promote democracy in China.

When Yang Jianli tried to return, Chinese consular officials refused to renew his passport. Using a friend's passport, he came to China in 2002 to conduct research.

Authorities arrested him for entering the country illegally. Espionage charges followed, with the Chinese government alleging that Mr. Yang had received money from a Taiwanese organization in the United States in 1991 in exchange for gathering what officials termed "confidential papers" of the Chinese government. Mr. Yang's lawyers say the organization in question had given out grants for research on things such as fruit-growing techniques.

Human rights advocates dismissed the charges as purely political, and accused the Beijing authorities of using the spy charges to justify why they held Mr. Yang for so long without a trial. Nicholas Becquelin is with the Hong Kong office of the U.S.-based Human Rights in China group.

"The case has no merits at all. It was a political case," he said. "It was a political trial, and it is now a political sentence. The use of spying charges to stifle political dissent and silence political dissenters is common practice in China."

In espionage cases in China, the authorities are not required to release evidence to the defendant or the defendant's lawyers, and trials may be held behind closed doors.

Yang Jianli's sentencing came after the U.S. Congress sent a letter to Chinese President Hu Jintao last month, describing his prolonged detention as "extraordinarily inhumane."