Send this page to someone via email

Jordanian security forces freed tourists trapped inside a medieval castle on Sunday after storming the building where armed men had taken shelter following a shoot-out with police that killed at least 10 people, security sources said.

A Canadian woman, two other civilians and seven police officers were among the 10 killed during the exchange of gunfire between the assailants and security forces.

A second Canadian was among the 29 people who were taken to hospital, a spokesperson for Global Affairs Canada told Global News.

“Our thoughts and deepest sympathies are with the family and friends of all the victims, including the Canadian killed and the Canadian who was injured in the heinous attack in Jordan,” Global Affairs spokesperson John Babcock said in an email.

Police in the mountainous city of Karak had earlier freed 10 people, including foreign tourists, but some were still being held in the Crusader-era castle from where the gunmen shot at security forces who were surrounding it, a security source said.

Story continues below advertisement

Castle of Al Karak, Jordan, 12th century. (Photo by DeAgostini/Getty Images) Castle of Al Karak, Jordan, 12th century. (Photo by DeAgostini/Getty Images)

The identity of the assailants was not immediately clear.

A former government minister from Karak city, Sameeh Maaytah, said there were signs Islamist militants may have been behind the attack but the government has so far steered away from saying this.

Story continues below advertisement

“The operation is continuing, it has not ended and the criminals are still inside the castle … This was a group that was plotting certain operations inside Jordan,” Maaytah told pan-Arab news channel al-Hadath.

WATCH: Gunfire heard in police and gunmen shootout in Jordan 0:38 Gunfire heard in police and gunmen shootout in Jordan Gunfire heard in police and gunmen shootout in Jordan

Video footage on social media showed security forces taking groups of young Asian tourists up the castle’s steep steps to its main entrance as gunshots were heard overhead.

After the attack, the Canadian embassy in Jordan tweeted a warning to Canadians, advising them against all travel to Karak until further notice.

Global Affairs Canada told Global News that government officials “in Amman are actively working with local authorities to gather additional information and provide consular assistance at this difficult time.”

“The Government of Canada stands ready to assist Jordan in bringing the perpetrators of this heinous attack to justice,” Babcock said.

Story continues below advertisement

Dear #Canadians, we advise against all travel to #Karak city until further notice due to security incident, be safe! — Canada in Jordan (@CanEmbJordan) December 18, 2016

The castle is one of the country’s most popular tourist attractions.

WATCH: Tourists flee as gunfire rings out during attack on Jordanian city of Karak

1:04 Tourists flee as gunfire rings out during attack on Jordanian city of Karak Tourists flee as gunfire rings out during attack on Jordanian city of Karak

Prime Minister Hani al Mulki told parliament “a number of security personnel” had been killed and that security forces were laying siege to the castle. The Canadian government confirmed one of its nationals had been killed.

Police and witnesses said gunmen had earlier gone on a shooting spree aimed at officers patrolling the town before entering the castle, perched on top of a hill. They used one of the castle’s towers to fire at a nearby police station.

Police said the gunmen had arrived from the desert town of Qatraneh nearly 30 km northeast of Karak city, a desert outpost known for smuggling, where many tribal residents are heavily armed.

Story continues below advertisement

A Canadian tourist was killed during a shootout between police and armed men in Karak, Jordan on Sunday, Dec. 18. Global News

They had fled to Karak after an exchange of fire with the police at a residential building, security forces said.

Jordan is one of the few Arab states that have taken part in a U.S.-led air campaign against Islamic State militants holding territory in Syria. But many Jordanians oppose their country’s involvement, saying it has led to the killing of fellow Muslims and raised security threats inside Jordan.

Officials worry about radical Islam’s growing profile in Jordan and support in impoverished areas for militant groups.

*With Files from Global News