LAHORE, Pakistan – Islamic leaders Sunday rallied at least 15,000 people against an American official arrested in the shooting deaths of two Pakistanis and warned the government not to cave in to U.S. pressure to release the man.

The protest in the eastern city of Lahore, where the shootings took place, came as the U.S. Embassy once again insisted that the American has diplomatic immunity and was being detained illegally by Pakistan. But Pakistan has refused to budge, saying the matter must be decided by the courts.

The spat has revealed the fragility of a relationship Washington believes is crucial for success in Afghanistan and against al-Qaida.

“We warn the government and administration that … if they help the arrested American illegally, then this crowd will surround the U.S. Embassy and presidential palace in Islamabad,” Hafiz Hussain Ahmed, a senior official in the Jamiat Ulema Islam party, said during Sunday’s rally.

The United States has said the American, who has not been named, acted in self-defense when he shot two armed men who approached his car in Lahore on Thursday.

But many questions have been left unanswered, including exactly what the American did at the U.S. Embassy and why he was carrying a gun. The lack of clarity has fueled media speculation he may have been a CIA agent or security contractor, as well as questions over whether he qualified for diplomatic immunity. The embassy tried to provide a little more clarity in a news release Sunday titled “Facts About Diplomatic Immunity.” It said the man is a member of the embassy’s “technical and administrative staff” and thus enjoyed the same criminal immunity that all diplomats have under the Vienna Convention on Diplomatic Relations.

But legal arguments are unlikely to sway ordinary Pakistanis, many of whom dislike the United States and distrust their government in its dealings with Washington. This animosity is especially pronounced among hard-line Islamic groups, which oppose the war in Afghanistan and object to Pakistan’s alliance with the United States in fighting the Taliban and al-Qaida.

Sunday’s demonstration was organized by Jamaat-ud-Dawa, which is widely believed to be a front for the militant group that attacked the Indian city of Mumbai in 2008 and killed 166 people. The rally was originally called to protest changes to Pakistani laws that mandate the death penalty for insulting Islam. But many of the speakers used the opportunity to stoke anger over the recent shootings.

“An American scoundrel has killed two innocent youths in the streets of Lahore,” said the leader of Jamiat Ulema Islam, Maulana Fazlur Rahman. “It should be decided in the courts and any decision beyond the courts will not be acceptable to us. There should be an end to American hegemony in Pakistan.”