JERUSALEM: A former spokesman for Israeli Prime Minister Benjamin Netanyahu has been detained for allegedly leaking confidential documents that may have harmed Gaza hostage deal negotiations, a court said on Sunday.

Eliezer Feldstein was detained along with three other people, including security officials, said the court in the coastal city of Rishon LeZion.

News of the case has led the opposition to question whether Netanyahu was complicit in the leak -- an allegation denied by his office.

Critics have long accused the premier of stalling in truce negotiations and prolonging the war to appease his far-right coalition partners.

Israel’s domestic security agency and the army launched an investigation into the breach in September after two newspapers, British weekly The Jewish Chronicle and Germany’s Bild tabloid, published articles based on the classified military documents.

One claimed a document had been uncovered showing that then Hamas leader Yahya Sinwar -- later killed by Israel -- and the hostages in Gaza would be smuggled out of the territory into Egypt through the Philadelphi Corridor along the Gaza-Egypt border.

The other was based on what was said to be an internal memo from the Hamas leadership on Sinwar’s strategy to hamper talks towards the liberation of hostages.

The first document leaked turned out to be fake, and the internal memo was in fact written by lower-level Hamas militants, Israeli media reports said.

The Israeli court said the release of the documents ran the risk of causing “severe harm to state security”.

“As a result, the ability of security bodies to achieve the objective of releasing the hostages, as part of the war goals, could have been compromised,“ it added.

Key opposition leader Yair Lapid told journalists on Sunday the details of “the serious security affair in Netanyahu’s office should alarm every Israeli”.

“This affair originated in the prime minister’s office, and the investigation needs to determine whether it was not under the prime minister’s orders,“ Lapid added.

“According to suspicions, Netanyahu’s associates leaked secret documents and forged classified documents to undermine a possible hostage release and to build a media campaign against the hostages’ families.”

Another leading opposition figure, Benny Gantz, said: “This is not a case of suspected leaks but rather profiteering with state secrets for political purposes.”

On Friday, Netanyahu denied the allegations, saying “the document published by Bild had never arrived” at his office.

Without mentioning Feldstein by name, he said the former aide “had never taken part in security meetings or consulted confidential documents”.