Nairobi, Kenya (CNN) -- Armed gunmen waged a tense standoff with Kenyan police and soldiers inside an upscale Nairobi shopping mall early Sunday, hours after brazenly gunning down shoppers, diners and others.
Bodies still littered the lobby and ground floor of the Westgate Mall around 10:30 p.m. (3:30 p.m. ET), more than 10 hours after the attack began, according to the Kenya National Disaster Operation Centre.
There were 39 confirmed dead at that point, according to Kenya's president, who added that his close relatives are among those killed. Two gunmen, including one who was detained after being shot, are also dead. Francis Kimenia, secretary to the Cabinet, tweeted another 293 people got treatment at three area hospitals, which "are appealing for more blood."
It's possible the death toll might grow given the attackers had hardly given up and an unknown number of innocent civilians, perhaps dead or being held hostage, remained inside the mall Sunday morning.
Al-Shabaab, an al-Qaeda-linked militant group based in Somalia, claimed responsibility for the carnage and vowed not to negotiate with Kenyan authorities. It claimed that "all Muslims" were escorted from the mall before the attack -- suggesting that its targets were people who didn't believe in their extreme form of Islam.
Shooting witness: We crawled under cars
Witness: We saw lots of blood
Gunmen take hostages at Kenya mall
"The Mujahideen are still strong inside #Westgate Mall and still holding their ground," the group said late Saturday via Twitter. "All praise is due to Allah!"
Kenyan authorities, though, insist they have the upper hand, where it's now early Sunday morning.
Police tweeted that the attackers "have been isolated and pinned down in a room by security forces." And Joseph Ole Lenku, the national government's cabinet secretary for interior and coordination, hinted that the worst should be over.
"Our security forces have taken control of the situation," Lenku said.
"Attackers of Westgate shopping mall have been isolated and pinned down in a room by security forces in the ongoing operation," the national police said on Twitter.
Kenya's president, Uhuru Kenyatta, blasted "the despicable perpetrators of this cowardly act (who) hoped to intimidate, divide and cause despondency among Kenyans and would like to (create) a closed, fearful and fractured society."
Kenya is no stranger to terrorism, including a 1998 bombing at the U.S. Embassy in Nairobi that left 213 dead and other attacks before and since tied to al Qaeda and related groups.
In a televised speech late Saturday, Kenyatta said his nation has "overcome" such attacks before, refusing to budge from its values or relinquish his security. And it will do so again, he promised.
"We shall hunt down the perpetrators wherever they run to," the president said. "We shall get them, and we shall punish them for this heinous crime.