A suicide attacker has struck near the Kabul police academy, killing at least 20 cadets and wounding 27 others, officials said, in the second major attack in the Afghan capital in 24 hours.

The bomber managed to place himself in a queue as police trainees were waiting to be searched before entering the academy, a senior intelligence official told AFP news agency on Friday, requesting anonymity.

"A suicide bomber on foot blew himself up near the academy," Deputy Interior Ministry Spokesman Najib Danish said. "Casualties are expected."

Al Jazeera's Jennifer Glasse, reporting from Kabul, said that fighting had also taken place close to the airport where a third explosion occurred on Friday, killing at least five people.

The incident, which comes as cadets were returning to the academy after their two-day weekend, marks a serious breach of security at a premier training institute for Afghan security forces.

Heavily-armed security officials cordoned off the area and ambulances with wailing sirens were seen rushing to the scene.

The academy in west Kabul is a premier training institution for police forces in Afghanistan, with between 2,000 and 3,000 cadets graduating every year.

The Taliban has claimed responsibility for the police academy attack [Reuters]

The bombing comes less than 24 hours after a truck bomb tore through central Kabul, killing 15 civilians and wounding 240 others in the first major attack in the Afghan capital since the announcement of Taliban leader Mullah Omar's death.

Afghan President Ashraf Ghani condemned the truck bombing and threatened a rapid and forceful response to the massive blast in the Afghan capital, which he said was aimed at diverting public attention from the Taliban's leadership struggle.

The Taliban has claimed responsibility for the police academy attack, group's spokesman, Zabiullah Mujahid, told AFP news agency.


Related: Who is the new leader of the Taliban?


Our correspondent described last night's blast as "very big". 

"We are in a very delicate stage in the peace process. It appears some members (of the Taliban) still want to fight. 

"The attacks probably are an attempt by some fighters to show that they still have some power, so that they have some clout when they come to the negotiating table," our correspondent said.

The attacks come as the Taliban steps up their summer offensive despite a bitter power transition within the armed group.

The carnage comes a day after Taliban fighters killed nine people in multiple attacks on police targets, including a truck bombing in the volatile eastern province of Logar.

Source: Al Jazeera and agencies