China's efforts to combat the spread of AIDS among drug users is being undermined by its harsh treatment of drug addicts, Human Rights Watch warned in a report Tuesday.

Injecting drugs is one of the main causes of new HIV infections in China, which has helped drive more funding and attention to treating drug addiction.

But China's "pragmatic" and "bold" approach to AIDS is at odds with punitive treatment of drug users, including cases where some were detained when entering or leaving HIV testing and treatment centers, the report warned.

"Drug users in rehabilitation centers are treated as prisoners, not patients, and subject to abusive and inhumane conditions of confinement," said the report.

The report was based on interviews with 19 drug users and 20 officials in the summer of 2007 in the border region of Guangxi, where almost all AIDS cases stem from drug use.

By the end of 2007, China had about 700,000 cases of HIV/AIDS, but the sources cited in the report estimated many unreported cases in their communities.

China has significant regional variations in how it approaches both AIDS and drug addiction, the report said.

Chinese communists wiped out opium use when they took power in 1949, blaming it for China's weakness in the face of demands by Western powers.

But heroin and, more recently, "party" drugs have returned with the increased trade and prosperity of the last 30 years.

The number of registered drug addicts in China reached 1.08 million as of October, up from 785,000 in 2005, the Xinhua news agency said Friday, citing the ministry of public security. Nearly four-fifths of those are heroin users.

China planned to build 45 non-compulsory drug treatment centers with a more "friendly environment," whereas in the past it has only had compulsory centers, the ministry said.

Drug users are regularly detained by police, who sometimes wait outside China's 500 methadone clinics, the report said.

"Detox" centers and re-education through labor programs are "prison-like," with abusive guards, minimal medical treatment and work without pay, it said.

AIDS testing is rarely confidential, it added, making potential sufferers reluctant to get tested until they are already sick. Fear of discrimination and stigma, as well as fees, also deters people from seeking testing, the report said.

People who undergo mandatory testing in detention are not told the results, it said.

Human Rights Watch noted that non-governmental organizations had had some success locally if they kept a low profile, but were hampered by a legal requirement that they partner with a government agency. NGO workers also faced threats and arrest.

One of China's most prominent AIDS activists, Hu Jia, was jailed for subversion last year.