Pakistan's military on Monday declared an end to an all-night offensive to quell a Taliban siege of Karachi airport that left 24 people dead, including 10 militants, and threatens to destroy a nascent peace process.

"The attack is over and we have cleared the area of all militants and we will hand over the airport to the Civil Aviation Authority at 12 p.m.," a spokesman for the paramilitary Rangers, Sibtain Rizvi, told reporters after nearly 12 hours of fighting.

The attack at Jinnah International Airport in Pakistan's biggest city began just before midnight Sunday and raged until dawn, when the military said that all 10 attackers had been killed after they had stormed two areas equipped with suicide vests, grenades and rocket launchers.

But after authorities initially declared the area cleared, an AFP reporter witnessed fresh gunfire break out inside the airport — where explosions and fires had erupted during the night — prompting security forces to relaunch the operation.

The Tehreek-e-Taliban Pakistan (TTP) group said the attack was in revenge for its late leader Hakimullah Mehsud, who was killed in a US drone strike in November.

TTP spokesman Shahidullah Shahid also dismissed the Pakistani government's recent offer of a new round of peace talks as a ruse, and promised more attacks to come.

"Pakistan used peace talks as a tool of war," he told AFP.

"We have yet to take revenge for the deaths of hundreds of innocent tribal women and children in Pakistani air strikes.

"It's just the beginning, we have taken revenge for one (Mehsud), we have to take revenge for hundreds."

Talks to end the TTP's bloody seven-year insurgency in Pakistan have been underway since February, with little clear progress made so far.

Three huge suicide blasts

The assault will raise fresh concerns about Pakistan's shaky security situation, and questions about how militants were able to penetrate the airport, which serves one of the world's biggest cities.

Officials said the gunmen entered from two sides of the airport at around 11:00 pm on Sunday — the terminal used for the hajj pilgrimage to Mecca, and an engineering section close to an old terminal that is no longer in use.

An AFP reporter witnessed three huge blasts as suicide bombers detonated their explosives.

Smoke was seen billowing from the airport as fires raged close to planes parked on the runway, while militants, some dressed in army uniform, clashed with the airport's security force who were backed by police, paramilitary squads and elite commandos.

A senior intelligence official said it appeared the militants had aimed to hijack a plane that passengers were boarding at the main terminal, but that when they were repelled they went on the rampage.

"The passenger plane at Jinnah terminal was their target and when they failed to reach there they destroyed two private terminals in frustration," he told AFP.

After the attack was quelled, a bomb disposal expert in full protective gear was seen walking from the site carrying a suicide vest and a bag full of hand grenades.

Peace talks essentially in tatters

The assault on Jinnah International Airport in Karachi, Pakistan's sprawling commercial hub of 18 million people, all but destroys prospects for peace talks between the Taliban and the government of Prime Minister Nawaz Sharif, who came to power last year promising to find a negotiated solution to years of violence.

It also deals a heavy blow to Sharif's efforts to attract more foreign investors to revive economic growth and raises questions about security at the country's key installations.