The fate of asylum seekers held in Papua New Guinea remains unclear after the country's Supreme Court ruled their detention was unconstitutional.
Australia sends asylum seekers to the Manus Island detention centre under its offshore processing policy.
The Australian government is still waiting for advice from Papua New Guinea, according to media reports.
Australia's Immigration Minister Peter Dutton said the centre was Papua New Guinea's "sovereign responsibility".
"It's part of PNG territory obviously and the decision of the Supreme Court is one that binds the PNG Government not the Australian Government," Mr Dutton said.
Mr Dutton also said the asylum seekers would not be allowed to come to Australia.
'Out of step'
Five judges on the Supreme Court's bench ruled the Manus Island camp breached section 42 of the constitution, which guarantees personal liberty.
The court said "all steps" should be taken to end the "illegal" detention.
Currently around 850 men are held on the island, around half of whom have been judged genuine refugees.
The president of the Australian Human Rights Commission Gillian Triggs said the court decision showed Australia's immigration policies were "increasingly out of step with international norms", according to a statement.
Manus Island: a controversial 'solution'
The camp first opened in 2001 under Prime Minister John Howard.
It was formally closed in 2008, but reopened in 2012 when a spike in asylum seeker arrivals became a major political issue for the Labor government.
In 2013 Australia agreed to give Papua New Guinea A$400m ($309m; £212m) in aid in exchange for housing a camp and to resettle genuine refugees.
Deadly riots broke out in February 2014 when local residents entered the facility. In January 2015 some detainees barricaded themselves inside their compound and went on hunger strike.
Private security contractor Broadspectrum, formerly Transfield Services, currently runs the camp.
Australia's government says its refugee policy has led to a sharp drop in the number of migrant boats.
UN agencies and rights groups have criticised conditions at the camp and say Australia is shirking its responsibilities towards refugees and migrants.
Papua New Guinea's constitution guarantees personal liberty for all people, except in defined circumstances relating to crime, illegal immigration and quarantine.
In 2014, Papua New Guinea's government amended section 42 of the constitution to add a paragraph that allowed for "holding a foreign national under arrangements made by Papua New Guinea with another country".
But the Supreme Court ruled this amendment was unconstitutional, as it did not meet a requirement to respect "the rights and dignity of mankind".
No appeal
It said that because the asylum seekers and refugees had not voluntarily entered Papua New Guinea, the situation of illegal immigration did not apply to them.
"The detention of the asylum seekers on Manus Island in Papua New Guinea… is unconstitutional and illegal," it said.
"Both the Australian and Papua New Guinea governments shall forthwith take all steps necessary to cease and prevent the continued unconstitutional and illegal detention of the asylum seekers or transferees at the relocation centre on Manus Island and the continued breach of the asylum seekers' or transferees' constitutional and human rights."
The MP for the region when the detention facility is located, Ronnie Knight, told the Australian Broadcasting Corp that the decision could not be appealed against.
"Our Supreme Court is the highest court in the land.
"It's basically the only way they can go, and as far as they can go. I don't think there's much that could be done," Mr Knight said.
After the court decision the opposition Labor party urged the government to hold urgent talks with Papua New Guinea, while opponents of hard-line immigration policy declared offshore processing of asylum seekers dead.