LONDON — British police were scrambling Saturday to work out how a man convicted of terrorism offenses managed to carry out a deadly stabbing attack on London Bridge a year after his release from prison.

Usman Khan, 28, was attending an event for a program that works to rehabilitate prisoners before launching the attack that saw him stab several people and brandish what turned out to be a fake suicide vest. He was shot dead by officers after members of the public intervened.

In addition to the suspect, a man and a woman were killed in the attack and an additional three people — one man and two women — were wounded and taken to hospital.

Metropolitan Police Assistant Commissioner Neil Basu said on he could not name victims until they had been formally identified by the coroner.

On Friday night, he said Khan "was known to authorities," adding that "a key line of inquiry now is to establish how he came to carry out this attack."

Khan had been convicted in 2012 for his part in an al-Qaeda-inspired plot to blow up the London Stock Exchange and other major sites including the U.S. Embassy. He was originally given a 16-year prison term but was released early “on license,” meaning he had to meet certain conditions or face being locked up again.

Britain’s Parole Board said in a statement it had no role in releasing Khan, who “appears to have been released automatically on license (as required by law), without ever being referred to the board,” it said.

The circumstances of the attack could elevate the issues of terrorism and criminal justice just weeks ahead of a crucial Dec. 12 election that has thus far been dominated by Brexit and health care.

Prime Minister Boris Johnson addressed the subject before chairing a meeting of the government's emergency committee late Friday.

Johnson said he had "long argued" that it is a "mistake to allow serious and violent criminals to come out of prison early."

"It is very important that we get out of that habit and that we enforce the appropriate sentences for dangerous criminals, especially for terrorists, that I think the public will want to see," Johnson said.

Opposition Labour Party leader Jeremy Corbyn said he was horrified by the attack.

"We must and we will stand together to reject hatred and division," said Corbyn, who trails Johnson in opinion polls.

Both leaders said they would scale back campaigning in the immediate wake of the attack.

The attack will likely prompt British police to review the conditions placed on released convicts, junior interior minister Brandon Lewis told BBC radio Saturday.

"There are conditions that are put on people in this situation and one of the things the police will be looking at is those conditions as part of that investigation," said Lewis.

Ahead of the attack, Khan had been attending an event called Learning Together at Fishmongers' Hall, a historic building adjacent to the bridge, police said.

Learning Together is a program led by Cambridge University which aims to provide education to people in prison alongside university students.

"I am devastated to learn that today's hateful attack on London Bridge may have been targeted at staff, students and alumni," Cambridge University president Stephen Toope said in a statement.

Khan was living in Staffordshire, about 150 miles north of London, and police were searching his address late Friday. Police said they are not actively investigating other suspects.