Australia's highest court ruled Wednesday that asylum seekers can't be sent to Malaysia, a major blow to the government's plan to stem an influx of people attempting to reach Australia by boat.

The High Court reached a 6-1 majority decision to make permanent an injunction that has prevented Australia from transferring 800 asylum seekers to Malaysia in return for Malaysia sending 4,000 registered refugees for resettlement. The ruling cannot be appealed.

Australia has long attracted asylum seekers hoping to start a new life, with more than 6,200 arriving by boat last year. Most are from Afghanistan, Sri Lanka, Iran and Iraq, and use Malaysia or Indonesia as a starting point for a dangerous sea journey to Australia.

mi-aus-boat-cp-rtr2ppxk

Australia's top court rejects a deal between Malaysia and Australia to swap refugees in a contentious new strategy aimed at deterring asylum seekers from undertaking perilous boat journeys to Australia. ((Renee Schipp/Reuters))

The government had maintained that the deal struck in consultation with the UN refugee agency, UNHCR, would withstand any legal challenge. Government lawyers had argued in court that Australia could lawfully declare Malaysia a safe third country to process refugee claims even though it had no domestic or international legal obligations to protect refugees.

The court said in a statement that Malaysia has not signed the UN Refugee Convention and the deal with Australia did not legally bind Malaysia to recognize the status of refugees under its domestic law. It said any suitable third country must have obligations under international or domestic law to protect asylum seekers and refugees.

The court also said Immigration Minister Chris Bowen had no legal power to remove from Australia asylum seekers whose refugee claims have not yet been determined. The government did not immediately comment on the ruling.

The case was brought to the court by 16 asylum seekers who were to become the first to be flown to Malaysia from the Australian territory of Christmas Island.

The government had planned to post video on social networking sites Facebook and YouTube showing the asylum seekers boarding the first chartered flight to Kuala Lumpur as a way of deterring others from coming by boat to Australia.

Malaysia has already begun sending registered refugees to Australia from among 93,000 now in that Southeast Asian nation under the deal.

mi-australia-malaysia-cp-01

Malaysian Home Minister Hishammuddin Hussein, foreground left, and Australian Immigration Minister Chris Bowen, foreground right, sign documents to swap refugees between the two countries in July. ((Lai Seng Sin/Associated Press))

The ruling came after two fires broke out Wednesday at an immigration detention centre in northern Australia during a protest involving alleged people smugglers.

Both blazes were extinguished and no one was hurt, though there were reports some of the detainees were throwing objects at firefighters, an immigration department spokesman said on customary condition of anonymity.

Most of the people involved in the protest at the Northern Immigration Detention Centre in Darwin were Indonesian crew members from boats carrying asylum seekers to Australia as part of people smuggling operations, the official said. He had no further details, and would not elaborate on what sparked the unrest.

Protests at detention centres have become relatively common.

The detainees involved in the protest were upset that officials had not agreed to certain requests regarding how they could celebrate the end of Ramadan, Islam's holy month of fasting, said refugee advocate Ian Rintoul, who spoke by phone with detainees inside the centre.

The fire caused extensive damage to 20 rooms, said Rintoul, a spokesman for the Refugee Action Coalition. No asylum seekers were  involved in the protest, he said.