Anders Behring Breivik, who killed 77 people in two separate attacks in Norway on July 22, appeared in court in Oslo on Monday for his first public hearing. He admitted perpetrating the massacre, but refused to plead guilty.

­Breivik was ushered into the courtroom by six policemen. A few minutes into the hearing, the judge asked Breivik if he admitted his guilt. Instead of answering, the accused started to read a speech he had prepared in advance.

"I am a military commander in the Norwegian resistance movement and Knights Templar Norway. Regarding the competence of the court, I object to it because you received your mandate from organizations that support hate ideology and because it supports multiculturalism," Breivik was quoted as saying by Reuters.

However, he was quickly interrupted by the judge.

Court officials then thwarted an attempt by Breivik to address victims' families.

The purpose of the hearing was to determine new terms for Breivik’s custody pending his trial. The session lasted no longer than 30 minutes. The prosecution asked the court to keep him in jail for a further 12 weeks.

The hearing was the first opportunity for the media, surviving victims and victims' relatives to hear Breivik speak publicly. More than 600 people, including press and victims’ relatives, were allowed access to the courtroom. Around 300 seats were made available for the general public and around 170 seats were also set aside for journalists, who were banned from earlier hearings.

Public interest was high with people gathering outside the Oslo City Court more than four hours before the hearing was due to begin in the hope of securing a seat in the courthouse. As a security measure, metal detectors were installed at the entrance to the court to screen all visitors.

Breivik’s defense attorney, Geir Lippestad, said in a TV interview that Breivik feared he might be shot in the courtroom.

Many survivors and victims’ families expressed disappointment that the hearing was opened to the public. They compared their courtroom encounter with Breivik to “torture victims meeting their torturer after a war,” the News in English website reported.

Ever since the massacre in July, survivors have complained that simply seeing Breivik’s photo on the front pages of newspapers has been a torture to them. Court officials insisted the media would not be allowed to cite anything said in court, and no photography or video recording would be permitted. However, the judge later lifted the reporting ban.

Breivik successfully appealed a prosecution request that his testimony be delivered to the court via video link from the prison where he is being held just outside Oslo. His wish to appear before the court in person was granted after the Supreme Court on Friday overturned two lower court rulings. Breivik has appeared at two previous hearings, but they were held behind closed doors. His trial proper will start in April.

Breivik’s bomb attack on Oslo and his subsequent shooting spree at a Labor Party youth camp on nearby Utoya Island on July 22 cost 77 lives and is the worst tragedy to hit Norway since World War II.