With less than two weeks before Britain heads to the polls, law and order has raced to the top of the election agenda after Usman Khan, wearing a fake suicide vest and wielding knives, killed two people on Friday before being shot dead by police.
Johnson's Conservatives have long championed tough police and prison measures, but opposition parties have criticized the governing party for overseeing almost a decade of cuts to public services.
Trying to distance himself from those cuts, Johnson said if he won the Dec. 12 election he would invest more money in the prison system and make sentences tougher.
"We are going to bring in tougher sentences for serious sexual and violent offenders and for terrorists," he told the BBC's Andrew Marr show.
"I absolutely deplore the fact that this man was out on the street, I think it was absolutely repulsive and we are going to take action."
He was keen to portray his rival for prime minister, Labour leader Jeremy Corbyn, as being weak on crime, blaming the opposition party for bringing in a law that automatically released some prisoners early when it was in government.
Corbyn, a veteran peace campaigner, said he believed convicted terrorists should "not necessarily" serve their full prison terms, suggesting it would depend on the nature of their sentence and also how they had behaved in prison.
"It depends on the circumstances, it depends on the sentence, but crucially it depends on what they've done in the prison," Corbyn told Sky News.
Despite criticizing cases where police and the army were accused of operating a shoot-to-kill policy in Northern Ireland, the Labour leader said the police had no choice but to shoot the attacker dead.
INVESTIGATION
Khan's attack on a Friday on London Bridge stirred memories of Britain's last election in 2017, when three militants drove a van into pedestrians in the same part of the capital and attacked people, killing eight and injuring at least 48.
Khan's rampage was brought to an end, in part, because of bystanders, who wrestled him to the ground before the police shot him dead. So far the police have found no evidence to suggest Khan was working with others.
Queen Elizabeth expressed her "enduring thanks to the police and emergency services, as well as the brave individuals who put their own lives at risk to selflessly help and protect others."
Three people remain in hospital, two of them in a stable condition, after Friday's attack. The third person is suffering from less serious injuries.
The attack brought a somber tone to what has often been an ill-natured election campaign, which is presenting voters with a stark choice - Labour's promise to raise taxes on the rich and businesses to fund a much expanded state or the Conservatives' pledge to "get Brexit done" and move onto other issues.
While Corbyn's team struck a moderate tone, with his top legal policy adviser Shami Chakrabarti questioning whether it was the time to make "knee-jerk" policy changes, Johnson again said only he could deliver Brexit, allowing Britain to move on to reforms such as to the criminal justice system.
"Obviously, I think we should be investing more in the criminal justice system," said Johnson."What we are doing now, under this new one nation Conservative administration, (is) we are investing ... It is new in our approach and it is new in the way we will tackle the issue of public services."