Updated

The man suspected of carrying out the Stockholm terror attack is a 39-year-old Uzbekistan who was known to security services, Swedish officials confirmed Saturday.

Four people were killed and 15 others injured when a hijacked beer truck plowed into a crowd of Friday afternoon shoppers in central Stockholm.

Authorities are confident the man in custody is the person who carried out the terrorist attack.

Anders Thornberg, head of the Swedish Security Service, said "the suspect didn't appear in our recent files but he earlier has been in our files."

Swedish police chief Dan Eliasson described the suspect as a “marginal character” and also said police found something in the truck that "could be a bomb or an incendiary object.”

“We are still investigating it," he said.

What police found was a homemade bomb, sources told Sky News which also reported Saturday that according to Swedish media reports the attacker "burned" himself while trying and failing to detonate it.

Other media reported that the device was found in the driver’s seat, but it was not known whether it was a bomb.

Police conducted overnight raids around Stockholm but declined to say if they were hunting any more suspects in the case. They said they have been questioning people in connection with the case but no one else has been detained. They said the suspect had been on their radar before but not recently, and did not explain why authorities apparently had not considered him a serious threat.

Swedish prosecutor Hans Ihrman said the person detained had been formally identified as a suspect "of terrorist offenses by murder," and should face a pre-trial custody hearing before midday Tuesday.

SUSPECT REPORTEDLY POSTED ISIS VIDEOS ON FACEBOOK

Hundreds of people gathered at the site of the crash Saturday afternoon, building a wall of colorful flowers on the aluminum fences to keep the people away from the broken glass and twisted metal. Some hugged police officers near the crash site.

Visiting the attack site, Sweden's Crown Princess Victoria laid roses on the ground Saturday and wiped away a tear.

"We must show a huge force, we must go against this," she told reporters.

The stolen beer truck traveled for more than 500 yards along a main pedestrian street known as the Drottninggatan before it smashed into a crowd outside the upscale Ahlens department store.

There was no immediate claim of responsibility. A Swedish newspaper reported that the suspect posted videos of ISIS atrocities on Facebook and “liked” a picture showing the bloody aftermath of the 2013 Boston Marathon bombings.

The Aftonbladet newspaper quoted a friend of the detained man as saying the suspect was a father of four and worked in construction.

"He never talked politics or religion," the friend said. "The only thing he talked about was getting more jobs so he could send money home to his family."

Nine adults and one child are still in the hospital, according to health officials. Four of those are seriously injured and the other six, including the child, have minor injuries.

Many in Sweden were shocked by the attack, questioning whether Swedish society -- considered democratic and egalitarian -- had failed in some way.

Although it was not clear how long the suspect had been in Sweden, the Scandinavian country prides itself on welcoming newcomers.

Still the country's open-door immigration policy and comparatively heterogeneous culture has led to frictions, sometimes urban unrest, especially in areas where many long-time immigrants feel disempowered.

In 2015, Sweden received a record 163,000 asylum-seekers.

The Associated Press contributed to this report.