Mohammed Rizalman bin Ismail was a military attache at Malaysia's Wellington embassy when the incident happened last year, and the case caused outrage when he fled to his homeland citing diplomatic immunity.
Naomi Campbell convicted for assaulting photographer
Rizalman was eventually extradited to face the New Zealand courts and had pleaded not guilty to attempted rape and burglary.
But with his trial due to start Monday, the original charges were dismissed when the 39-year-old admitted one count of indecent assault against Wellington woman Tania Billingsley.
Rizalman's lawyer Donald Stevens cited extenuating circumstances including mental illness, although prosecutors contest this.
The court heard that on May 9 last year Billingsley was at home in Brooklyn, the Wellington suburb where the Malaysian embassy is located, when she heard a knock on her bedroom door.
Teenager held for assault, murder of minor killed in botched escape attempt
Rizalman then entered wearing no trousers or underpants. She screamed and struggled with him, managing to push him out of the house before calling police.
"The victim was entitled to be very, very frightened at the situation confronting her," prosecutor Grant Burston said.
Stevens said Rizalman told police the pair had been to the cinema together that day, but the court did not hear whether Billingsley confirmed this.
The defence lawyer also denied that Rizalman's offending was sexually motivated.
Burston said experts would be called to dispute Rizalman's argument that he was mentally unwell, saying his behaviour was more consistent with "cannabis use and anxiety".
Indecent assault carries a maximum jail term of seven years in New Zealand.
Judge David Collins said a hearing into disputed aspects of the case would take place on Friday before sentencing.
Rizalman sat quietly in the dock as an interpreter explained proceedings to him. His bail was continued ahead of Friday's hearing.
Judge Collins said if a home detention sentence was imposed, and he stressed it was only a possibility, Rizalman may be allowed to serve it at the Malaysian embassy.
COMMENTS
Comments are moderated and generally will be posted if they are on-topic and not abusive.
For more information, please see our Comments FAQ