KABUL, Afghanistan – Taliban insurgents struck the heart of the Afghan capital and three eastern cities Sunday, firing automatic weapons and grenades at embassies, government buildings and NATO bases as they launched the spring fighting season with the boldest and most complex assault in years.

The multi-pronged attacks show the Taliban and their allies are far from beaten and underscored the security challenge facing government forces as U.S. and NATO forces draw down. The majority of international combat troops are scheduled to leave by the end of 2014.

The first blasts rocked the diplomatic quarter of Kabul on Sunday afternoon, and soon gunshots and rocket-propelled grenade fire were ringing out across the city. Smoke rose over the skyline as sirens wailed. A loudspeaker at the U.S. Embassy could be heard barking: “Duck and cover. Move away from the windows.”

One police officer and 17 militants were killed in the attacks, the most widespread in the Afghan capital since an assault on the U.S. Embassy and NATO headquarters last September blamed on the Haqqani network, a Pakistan-based insurgent group allied with the Taliban. Fighting continued more than 12 hours after the first blasts, with explosions echoing into the night.

The sophistication and firepower of the latest strikes, as well as the high-profile government and foreign targets, bore the hallmarks of the attack last fall and others carried out by Haqqani insurgents.

As in the earlier attack, armed insurgents took over half-built buildings Sunday and used them to fire down on nearby embassies and bases. In the streets of Kabul’s Wazir Akbar Khan neighborhood, where a NATO base and a number of embassies, including the U.S. Embassy, are located, residents scrambled for cover as gunfire rained down from all directions.

“I saw two Land Cruisers pull up and two militants jumped from the car,” said Mohammad Zakar, a 27-year-old mechanic who has a shop near the building commandeered by the militants. “They opened fire on an intelligence service guard … They also fired and killed an Afghan policeman and then they jumped into the building. All the shops closed. I ran away.”

Across town at the parliament building, insurgents climbed to the upper floors of another empty building and fired on lawmakers below. A few legislators climbed on the roof of the parliament and fired back.

“I shot up to 400 or 500 bullets from my Kalashnikov at the attackers,” said Mohammad Nahim Lalai Hamidzai, a lawmaker from Kandahar.

Militants also attacked a NATO site on the outskirts of Kabul, where a joint Greek-Turkish base came under heavy fire and forces responded with heavy-caliber machine guns. A police officer said a suicide bomber inside a building near the base was shooting toward the Kabul Military Training Center.

The eastern cities of Jalalabad, Gardez and Pul-e-Alam also came under attack, with suicide bombers trying to storm NATO bases.

Taliban spokesman Zabiullah Mujahid said dozens of suicide attackers and gunmen were sent into four provinces in an assault that had been planned for two months to show the extent of the insurgency’s power after NATO commanders called the Taliban weak and said there was no indication they were planning a spring offensive.

“We are strong and we can attack anywhere we want,” Mujahid said, calling the attacks an opening salvo ahead of the yearly spring offensive, when warmer weather typically brings increased attacks.

The near-simultaneous assaults were the latest blow to an international effort that has been on edge for months as distrust grew between international and Afghan forces following the release of a video purporting to show Marines urinating on Taliban corpses, as well as the burning of Qurans at a U.S. base and a deadly attack by a U.S. soldier that killed 17 Afghan villagers.

Those tensions had appeared to be subsiding in recent weeks and the relatively quiet start to spring had brought hope: a deal governing night raids, talks with the Hizb-i-Islami insurgent group and the appointment of a new head to the High Peace Council — which is trying to negotiate with the Taliban.

That quiet was shattered Sunday. More than a dozen explosions rocked Kabul and heavy gunfire crackled through the streets for hours.

At least one police officer was killed in Kabul. Seventeen militant fighters also died, including four in Kabul, and two others were arrested, the Interior Ministry said. Seventeen police officers and 14 civilians were wounded in attacks across four provinces.

Lt. Col. Jimmie Cummings, a spokesman for the U.S.-led coalition, said the U.S., German and British embassies and some coalition and Afghan government buildings took direct and indirect fire.

U.S. Marine Gen. John Allen, the top commander of U.S. and NATO forces in Afghanistan, said the coalition was standing by to support the Afghan forces if needed, but had not been called in.

“I consider it a testament to their skill and professionalism — of how far they’ve come — that they haven’t yet asked for that support,” Allen said in a statement.