Justice Steven Strickland deferred a decision on the release of five child detainees, however, due to a lack of evidence.
Lawyers for the five children, two boys and three girls aged between five and 14 from the one family, had sought their immediate release.
The two brothers are detained with their father at South Australia's Baxter detention centre, while their sisters are with their mother on a home detention centre programme in the outback town of Woomera.
The hearing resulted from a ruling by a full bench of the same court in June that the Family Court had jurisdiction to determine the future of child detainees.
Minister's challenge rejected
"(I have determined) prima facie that children are unlawfully in detention and there is a real issue to be tried about that."
-Family Court Judge Steven Strickland
In its landmark decision, the court said the government's policy of mandatory detention of all asylum seekers pending processing of their cases violated the law when it involved the indefinite detention of minors.
Immigration Minister Philip Ruddock immediately challenged the ruling on the grounds that Australian courts should not have jurisdiction over illegal immigrants and asked that the ruling be frozen pending a formal appeal to the High Court.
"The court has made a decision which we believe is flawed," he told the Australian Associated Press.
His application was rejected.
Justice Strickland, hearing an application for an interim order to release the siblings pending a full trial of their case starting on September 15, said Friday he had determined "prima facie that children are unlawfully in detention and there is a real issue to be tried about that".
But he said there was insufficient evidence before him to decide the issue of the five children.
He gave parties involved in the action the option of delaying the judgement until the 15 September hearing or adjourning the interim hearing to a date in the near future.
Release of the five children would likely unleash a flood of court cases since refugee rights advocates say more than 100 children are being held in mainland immigration detention centres, including about 80 in Baxter.
PM's tough stance
Australian Prime Minister John Howard has rejected claims that mandatory detention of refugees is immoral or illegal, telling Melbourne's ABC radio that mandatory detention would not happen if people entered the country legally.
Howard takes a hard line.
"This is a difficult area, we don't like mandatory detention and if people didn't endeavour to come to Australia illegally, and in breach of international refugee processes, then it wouldn't occur," he said.
His government has come under repeated fire for perceived human rights abuses in its harsh treatment of refugees.
Any ruling in favour of the children will not apply to the hundreds of children being detained offshore, however.
This practice is also coming in for heavy censure from Australia's political opposition and human rights groups.
Australian opposition leader Simon Crean told Perth radio that the government must be tough on border protection but could show compassion at the same time.
"Whatever the argument is about their parents and the circumstances in which they might get here, the kids are the innocent ones," he said.
Last month activists from Amnesty International marched on Prime Minister John Howard's Sydney home last month, demanding Australia immediately release 112 child detainees being held on the Pacific island of Nauru.
Chairmen and directors from the rights group's Asian missions warned that Australia was risking its reputation as a human rights leader by continuing to detain children.