About four hours later Iwikau broke in via a door or window.
He crept into the woman's bed as she slept and kissed her, "penetrating her mouth with his tongue".
Iwikau repeatedly asked her to remove her pants and, thinking he was her partner, she did so.
After molesting the victim and attempting to pull her on top of him, the defendant tried to pull off his own pants.
As the woman began to wake up, she saw her boyfriend asleep on the couch and screamed for help.
Iwikau bolted down the hallway and out of the building.
When interviewed by police he told them he could not remember what happened that night.
The High Court at Auckland today heard Iwikau will be considered for a sentence of preventive detention - an indefinite prison term.
He will now be assessed by a psychologist and psychiatrist and their reports will be provided to counsel and the sentencing judge.
Preventive detention is usually imposed on people who have a long history of violent or sexual offending and is designed to protect the public.
The sentence comes with a standard non-parole period of 10 years, but a judge can extend that in "exceptional cases".
Iwikau will learn his fate in February.