The mystery surrounding a woman going by the name of “Linda” who showed up at a Toronto homeless shelter in September with no memory of who she was appears to be over.

After an intensive three-month investigation, Toronto police confirmed Tuesday that the woman is in fact Linda Hegg, a 56-year-old from Newark, Delaware, who was reported missing in early November.

That’s just a few weeks after “Linda” walked into a homeless shelter in downtown Toronto, carrying only a tote bag filled with scraps of paper and a bottle of water.

How she happened to arrive in Toronto and how she got over the border without any identification is still a mystery.

Police had to work for weeks to make the identification. They issued news releases with Linda's photo, hoping that someone in the local area would recognize her, but had no success.

Even when they expanded the alerts nationwide and noted that Linda's undisclosed medical condition was worsening, they got no response.

The FBI helped to conduct a fingerprint search and a search of facial recognition software at points of entry into the United States, but came up empty.

Meanwhile, in Delaware, no one knew Hegg was missing until Nov. 5, when her mail carrier noticed that mail was piling up at her apartment door. When the mail carrier inquired about the woman with neighbours, they said they hadn't seen her for weeks.

Police in Newark issued a statement of their own on Nov. 7, which an amateur Web sleuth spotted before contacting police. With the help of DNA, police were able to confirm Linda's identity on Dec. 10.

“When officers spoke to Linda and told her that they knew who she was, she smiled and her eyes lit up. It was the first time in two months investigators had seen Linda smile,” police said in a statement Tuesday.

Hegg has now been returned to Newark and is resting comfortably in hospital with family at her side.

Hegg's 83-year-old father has told The Toronto Star that his daughter suffers from "fugue amnesia," a rare and usually temporary psychiatric disorder marked by wandering.

The state is usually short-lived but can last months or longer. After recovery from fugue amnesia, previous memories usually return intact, though memories of the fugue episode are often lost.

The Toronto Police Service said a number of agencies helped solve the “Linda” mystery, including the shelter that took Linda in, Toronto East General Hospital, the U.S. Navy, Centre of Forensic Sciences, the Canadian and U.S. Border Services Agency and the media.

“Working together with all these agencies made it possible to get Linda home for the holidays,” police said in a statement.

It’s not clear what role the U.S. Navy played in the investigation, but Hegg's father told The Toronto Star that Linda served in the Navy until 1986, when she retired as a lieutenant.