An Afghanistan National Army (ANA) soldier fires his weapon at the site of a clash between insurgents and security forces on the Indian Consulate in Herat. (AP Photo)
The four gunmen who attacked an Indian consulate in Afghanistan's on Friday had a plan to capture the complex and take the diplomatic staff hostage, said officials who have been briefed on the situation.
All four attackers, armed with assault rifles, under barrel and rocket propelled grenade launchers were killed after an intense fight that lasted almost nine hours.
Read: Indian consulate attack in Herat: India points to terror from beyond Afghan border
The staff and guards of the consulate in Herat, Afghanistan's third largest and supposedly peaceful city, are safe.
"The determination of attackers can be gauged from the fact that the last one of them was neutralised only after the Afghan forces flattened the building near the consulate with explosives, burying him under the debris," said a senior security officials on the condition of anonymity.
"It seems that they came prepared to capture the compound and hold the Indian staff there as hostage," he added.
In the wake of Afghan general election, Indian installations in the war-torn country had been warned about possible attacks, said Indo-Tibetan Border Police (ITBP) director general Subhas Goswami.
Read: Attack on Indian consulate in Afghanistan's Herat thwarted, all four gunmen killed
The ITBP guards all five Indian installations in Afghanistan--- the embassy in capital Kabul and four consulates in Herat, Mazar-e-Sharif, Jalalabad and Kandahar.
"One attacker managed to climb the 15-feet high wall of the compound which is not marked as an Indian installation and situated in a residential area," said Goswami.
"He was challenged by our commandos and shot dead there. The other three attackers ran away and took shelter in a nearby building, but they were also killed by Afghan security forces. Besides being heavily armed, we found dry fruits on the attacker as well," added Goswami.
ITBP had recently reinforced its deployment by sending 79 more commandos there. The force has now more than 200 commandos to guard all five installations.
Security officials say the timing and place of attack is hard to miss, as it comes at a time when Pakistani Prime Minister Nawaz Sharif has been invited for the swearing-in ceremony of Narendra Modi.
"But targeting Herat is puzzling, as it borders Iran and has been under the influence of warlord Ismail Khan who has friendly relations with India," the security official said.
"Herat and Mazar-e-Sharif are comparatively peaceful. Though Herat still has pockets of Taliban influence in areas like Pashtun Zarghun, we will have to wait till the identity of attackers becomes clear. Possibly, the attackers chose faraway Heart so that the attack is not traced to Pakistan or its proxies," he added.
It is not the first time than an Indian installation in Afghanistan had come under attack.
In August last year, the Jalalabad consulate came under attack and before that Indian embassy in Kabul was attacked in 2008 and 2009.
"All attacks have been traced back to Pakistani spy agency ISI or its Afghan proxies like the Haqqani Network. Pakistan has repeatedly accused that Indian consulates are trying to destabilise Pakistan. But India has taken many developments works in Afghanistan, which have been praised by the international community," another official familiar with Indian intervention in Afghanistan said.