AMMAN, Jordan (REUTERS) - A Jordanian police officer shot dead two American civilian contractors, a South African contractor and a Jordanian on Monday at a US-funded security training facility near Amman before being killed in a shootout, the authorities said.
US President Barack Obama said he was treating the attack at the King Abdullah Training Centre - in which four Jordanians and one Lebanese citizen were wounded - very seriously and a full investigation was under way.
The gunman's background and motive were not immediately known. But Jordan is a staunch US ally in the Washington-led campaign against ISIS (Islamic State in Iraq and Syria) militants who hold large areas of neighbouring Syria and Iraq, a position Jordanian officials say leaves the kingdom vulnerable to jihadist attacks.
"This incident sadly does not come as a surprise as the threat of Islamist terrorism has only increased in the region in the last few years in the aftermath of Syria and Iraq. As much as pre-emptive measures have been taken, it is impossible to eradicate all risks," said a senior Jordanian official who requested anonymity, citing political sensitivities.
The gunman was a police captain and co-trainer at the King Abdullah Training Centre, a senior Jordanian official said. The attacker's identity and details of his background were not immediately released.
The US Embassy in Amman said two American civilian security contractors and a South African contractor were shot to death, and the slain Jordanian was a translator according to the Jordanian government.
"The investigation is ongoing and it is premature to speculate on motive at this point," an embassy statement said.
"We are working closely with the government of Jordan and local security services on a full and comprehensive investigation. We strongly condemn this incident and we deeply appreciate the cooperation and support received from our Jordanian partners."
A US official said the two Americans were working for the US State Department's International Narcotics and Law Enforcement Affairs Bureau training Palestinian security forces.
The shooting spree took place on the 10th anniversary of al Qaeda suicide bombings that targeted three Amman luxury hotels and killed 57 people, the worst militant attack in the history of Jordan, a staunch US ally.
Security sources said several earlier militant plots to attack the King Abdullah training centre had been foiled.
Jordanian government spokesman Mohammad Momani said the attacker was gunned down by Jordanian security forces inside the training centre. He did not commit suicide as security sources had earlier reported.
The training facility was set up on the outskirts of the capital Amman after the 2003 US invasion of Iraq to help rebuild the shattered country's post-war security forces and to train Palestinian Authority police officers.
Jordan hosts several hundred US contractors who are part of a military programme to bolster the kingdom's defences, including the stationing of F16 fighter jets that use Jordanian airfields to hit ISIS positions in neighbouring Syria.
But Jordan's role in the war against Islamic State has raised disquiet among some Jordanians about instability at their borders. They fear that Amman's enhanced role in the campaign might provoke extremist bloodshed in their country.
The Jordanian authorities have since tightened security around sensitive government districts, increased surveillance of radical Islamists and jailed dozens on suspicion of plotting militant attacks on Israelis, Americans and other Westerners.
King Abdullah believes fervently that ultra hardline extremists pose an existential threat to the kingdom.
Since the civil war erupted in Syria in 2011, hundreds of Jordanians have joined Sunni Muslim militant groups in the insurgency against President Bashar al-Assad, according to Islamists close to the subject.
But Jordan's Western-aligned monarchy is torn by conflicting interests over Syria. It has tried to steer a middle course between that of Gulf Arab allies who want Assad ousted at almost any cost and its own concerns - echoed by Washington - that a radical Islamist victory in Syria would install a worse threat.
That ambivalence means that while Jordan has hosted small-scale US training of rebels and allowed modest quantities of Gulf-supplied arms to filter into Syria, it has ensured that its border has not become an easy conduit for guns and combatants.