Militants have killed six security personnel in an attack on a police training centre near the southern Afghan city of Kandahar, officials say.
At least three gunmen were also killed in the gun and bomb attack, which the Taliban say they carried out.
The insurgents were armed with rocket-propelled grenades and automatic weapons, police said.
Tens of thousands of Afghan police and troops are being trained to assume full security control once Nato leaves.
Afghan forces are frequently targeted by the Taliban and their allies, who want to oust the Western-backed government of Hamid Karzai in Kabul.
Kandahar has experienced some of the worst of the violence in Afghanistan in recent years and is seen as the spiritual homeland of the Taliban.
The gun battle inside the police training and recruitment centre lasted an hour and involved three attackers, say police. A Taliban statement said four of their fighters carried out the raid.
Witnesses heard a number of explosions. Reports say one or more suicide bombers could have been involved.
"Insurgents have blown up an ambulance vehicle full of explosives which killed six members of the national security forces and wounded 10 more," the Kandahar governor's office said.
A civilian was among the injured, it said.
US military helicopters and armoured vehicles were sent in to support the police.
Kandahar has seen a number of insurgent attacks on police in recent months.
In February, 19 people were killed in an assault on the city's police headquarters.
The BBC's Paul Wood in Kabul says Nato carried out a big operation in Kandahar and the surrounding area last year - halting and then reversing the Taliban's momentum, according to senior officers.
However, Nato officers acknowledge that progress is "fragile". Police and government officials are still regularly targeted.
All sides are expecting the level of violence in Afghanistan to increase, our correspondent adds.