Few people were on the streets around the bank because government ministries and businesses were closed on Wednesday as Afghanistan observed independence day.
James Bays, Al Jazeera's correspondent in Kabul, said the siege went on for more than four hours before police announced the fighting was over.
"We're told that the gunmen had planted rigged explosives around the building and that's where the policemen were wounded," he said.
"The Taliban says it is their operation. A Taliban spokesman told Al Jazeera there [were] five attackers equipped with suicide vests."
Bays said that security around the area remained tight and officials were attempting to keep reporters away.
"They are trying to prevent journalists here from filming in a way that I've never seen before in Afghanistan."
The Afghan government has called for an international media blackout on reporting violence on the day of the election, amid fears that security concerns could keep voters at home.
The government's appeal to the media was contained in a foreign ministry statement.
"All domestic and international media agencies are requested to refrain from broadcasting any incident of violence during the election process," it said.
Day of violence
The US military said three American troops had been killed in two incidents in southern Afghanistan.
The deaths bring to six the number of US deaths announced by the military on Wednesday. That pushes to at least 32 the number of US troops to die in August.
|Security forces in Afghanistan
are on high alert [AFP]
Al Jazeera's Nick Clark, reporting from Kabul, said there was "a real sense of unease in the capital ahead of Thursday's election".
"We are constantly being fed with information about various violent incidents around the country. There is heavy fighting around Kunduz city, which is in the north of Afghanistan ... between Taliban and government forces.
"This morning, we heard that the Taliban had kidnapped seven police officers from Kunduz province. The police have confirmed that five of them have been killed, and two remain kidnapped.
"In Bajis province, in the north, a truck carrying civilians hit a roadside bomb, 13 died.
"In the province of Kunar and Nurestan, the Taliban reportedly burnt down a polling station. In Ghazni last night, in central Afghanistan, an American helicopter fired at a police checkpoint and killed four policemen and injured two, so two policemen are still missing.
"It is a continually unfolding situation, just hours ahead of the polls opening tomorrow."
Al Jazeera's Hashem Ahelbarra, reporting from Mazar-e-Sharif in the north, said: "We do not know yet whether these are isolated events taking place in northern Afghanistan or more of a co-operated attempt by the Taliban ... to upset the election as the clock starts ticking down towards the voting day."
Wednesday's violence followed a series of attacks on Tuesday, including a suicide car bombing east of the capital along the Jalalabad-Kabul road, which targeted members of Nato's International Security Assistance Force (Isaf).
"I don't think these elections are transparent. In my opinion, the person who is in favour of Western countries will ultimately win, whether there are elections or not"
Maiwand Karbuk, a 29-year-old resident of Kabul
Eight people were killed in that attack, including a Nato soldier and two UN workers, and 52 wounded. The Taliban claimed responsibility.
The Nato-led military force in Afghanistan has vowed to make every effort to protect voters, saying that more than 100,000 international troops will refrain from offensive operations on election day.
But the Taliban has demanded that Afghans boycott the polls, threatening to cut off the fingers of those who vote and saying they will attack polling stations.
A statement from the Taliban on Wednesday said Taliban fighters were closing roads across the country, the Reuters news agency reported.
"From today onwards until the end of tomorrow, all main and secondary roads will be blocked for traffic and the mujahidin will bear no responsibility for whoever gets hurt," the statement said.
'Lot of warnings'
Maiwand Karbuk, a 29-year-old resident of Kabul, told Al Jazeera on Wednesday that he will not vote.
|The Taliban has vowed to disrupt the country's presidential election [AFP]
"[The Taliban] have given a lot of warnings. No one will take that risk to go to polling stations," he said.
He also said he believes the elections will not help Afghanistan.
"I don't think these elections are transparent. In my opinion, the person who is in favour of Western countries will ultimately win, whether there are elections or not."
Opinion polls are showing a lead for Hamid Karzai, the incumbent president, with 45 per cent of the ballot, but not an outright majority.
Without an outright majority, Karzai would be forced into a runoff with his closest challenger, predicted to be Abdullah Abdullah, his former foreign minister.