Motive of Egypt tourist resort killer 'not clear'
"The perpetrator of the attack is being investigated," the prosecution said in a statement reported by state-owned media.
"It has not yet been proven whether this was an individual act, a criminal act, an act of terrorism, or otherwise."
The prosecution also urged the media "to stop resorting to speculation or getting ahead of the investigation".
Judicial sources said the Hurghada assailant who had swum ashore from a public beach to carry out Friday's attack.
He confessed to sharing the ideology of the Islamic State group, although the jihadi organisation has not claimed responsibility.
The sources said the suspect, a 28-year-old from Kafr al-Sheikh province in the Nile Delta, north of Cairo, has been transferred to the capital for questioning.
The streets of Hurghada were being heavily patrolled and security was stepped up outside hotels on Saturday.
"I was sitting down in my shop when we heard people shouting. We ran outside and heard that someone had swum to the next door hotel and was attacking foreigners," said Rafic Rushdi, the owner of a hotel shop.
"After killing two women, he ran towards our hotel. He was shouting that he was not after Egyptians, and some Egyptians intervened to stop him."
After initial confusion over the nationality of the women killed, Berlin on Saturday said they were both German nationals, rather than Ukrainians as earlier reported.
"I am very upset by this cowardly crime, my condolences to the families of the victims," German Foreign Minister Sigmar Gabriel said.
Among the four others wounded were two Armenian women and a woman from the Czech Republic, authorities in those countries said.
It was not the first attack in Hurghada.
In January 2016, three tourists were wounded in a stabbing assault in the resort by two assailants with apparent IS sympathies.
Hurghada is one of Egypt's most popular beach resorts, especially with Ukrainians and other European tourists.
Egyptian authorities say they have boosted security at tourist sites.
Tourism provides the Arab world's most populous country with much-needed revenues.
Egypt has struggled to quash militant attacks led by the Islamic State group, whose local branch is based in the Sinai Peninsula, after the army ousted Islamist president Mohamed Morsi in 2013.
An IS bombing of a Russian airliner carrying holidaymakers from a resort in the south of the Sinai in 2015 killed all 224 people on board and decimated the tourism sector.
Russia suspended all flights to Egypt in response and has yet to resume them.
Agencies contributed to this report.