Death sentences recently handed down to two convicted Australian drug traffickers are presenting Malaysia with a crucial test of resolve in its war on a growing narcotics problem.

Faced with spreading addiction to heroin and other hard drugs, known here collectively as dadah, this relatively prosperous Southeast Asian country has adopted some of the world's toughest antinarcotics laws.

Under a law passed in 1983, possession of more than 15 grams of heroin or 200 grams of marijuana or hashish (slightly more than half an ounce and 7 ounces respectively) carries a mandatory penalty of death by hanging.

In June, parliament approved an extraordinary bill aimed at the kingpins of the narcotics trade who rarely can be convicted of actual possession. Called the Dangerous Drugs Bill, it allows authorities to detain suspected ringleaders indefinitely without trial or bail on the recommendation of the home minister and a special advisory board.

The Home Ministry says Malaysia has about 100,000 drug addicts, but opposition and academic sources estimate that there may be four to five times that many.

Since 1975, 31 persons have been executed for drug offenses, three of them under the law that made the death sentence mandatory. Nearly 60 others are on death row pending appeals.

Among the latest cases, death sentences were given in September to a Thai rubber-plantation worker for trafficking 951 grams (33 ounces) of cannabis and to two Malaysian brothers arrested with more than two pounds of heroin.

Others on death row include Kevin Barlow, 27, and Brian Chambers, 28, two Australian travelers caught with 180 grams of heroin at the Penang airport in November 1983 and sentenced this fall to be hanged. Both have appealed their sentences.

They are the first westerners convicted under the new law, and their case has attracted attention both in this country of nearly 16 million people and in Australia. While the courts have been tough on Malaysians and other Asians charged with drug trafficking, some leniency has been shown -- possibly by coincidence -- in the cases of at least two westerners.

But Prime Minister Mahathir Mohamad told a drug prevention seminar last month in Kuala Lumpur that there would be "no forgiveness" for foreigners convicted under Malaysia's tough narcotics laws. He said all drug offenders would be dealt with the same way, whether they were foreigners or Malaysians.

"There will be no compromise for those who are slowly killing our people," Mahathir told the seminar. "There will be no forgiveness for them."

This tough approach has spilled over into neighboring Thailand, where another Australian, Donald Roy Tait, was sentenced to death last month for possession of more than four pounds of heroin. According to observers, the case is apparently the first time a westerner has been sentenced to death. Tait has appealed.

In September, Malaysia's High Court freed Sebastiano Robert Pavone, 28, a former weight-lifting champion of Australia and bailiff from Sydney, who was sentenced to life imprisonment for heroin trafficking in 1983.

Two years ago, another appeals court commuted to life imprisonment the death sentence imposed on a 22-year-old French woman, Beatrice Saubin, who was arrested with 534 grams of heroin.

Lawyer Karpal Singh, an outspoken politician who was suspended from parliament last year for allegedly insulting Malaysia's king, argued that "the death penalty is not a deterrent" to heroin trafficking. In fact, he said, since the mandatory death sentence was introduced, incidents of drug trafficking have increased, with carriers demanding greater fees.

"What the government has to do is get to the root of the problem," Karpal said. He feels a first step should be to enforce "more stringent measures along the border" between Malaysia and Thailand.

The heroin and opium available here are said to come from the "Golden Triangle" area where the borders of Thailand, Burma and Laos meet. Burma accounts for 600 to 800 tons of the area's annual opium harvest, with Thailand and Laos each producing about 40 tons. Some of the opium is refined into heroin at jungle laboratories near the Burmese-Thai border. Drug syndicates then smuggle it to buyers in Southeast Asia and abroad.

While efforts to strike at narcotics bosses here have been widely praised, Karpal and other lawyers have voiced concerns about the Dangerous Drugs Bill. "I think any legislation providing for detention without trial cannot be supported," Karpal said.

Worries also have been expressed about the use of informers who received rewards for drug busts and about the prospects that innocent persons might be framed. Such a case surfaced recently when a Malaysian youth was freed after spending seven years in prison on what turned out to be a false charge of possessing heroin.

"There is a danger that our society is fast transforming itself into one of suspicion, fear and paranoia," wrote a Penang resident, Alice Tan, in a recent letter to a Kuala Lumpur newspaper. "Could these informants not be one of the dadah kingpins themselves?" she asked. "Could our police and government be unwittingly paying the traffickers disguised as informers handsome rewards, while the lesser criminals are being put to death?"

Regardless of such concerns, the crackdown on drugs appears to be having some impact if availability is any indication. Police report that a heroin shortage in Penang and neighboring states has driven addicts out into the open, leading to 150 arrests in Penang and 70 in Perak in one week this fall.

However, police also say the shortage has caused a sharp increase in petty crimes in Penang State as desperate addicts seek more money to buy heroin, which has quadrupled in price since the beginning of September.