Amid opposition protest and charges of a Cabinet-sanctioned cover-up, Israeli President Chaim Herzog today issued blanket pardons to the chief of Israel's secret security services and three of his deputies who had been accused of covering up the beating deaths of two handcuffed Arab prisoners in 1984.

The security chief, Avraham Shalom, resigned after all-night talks with senior Cabinet ministers, thereby allowing the government to avoid an official inquiry that threatened to embarrass Prime Minister Shimon Peres and Foreign Minister Yitzhak Shamir. Both had opposed creation of a special commission to investigate the potentially explosive scandal.

Peres said he will set up a special commission to determine future conduct of agents of the Shin Bet, or secret security services, "based on the lessons of the past." But the commission is not expected to have the investigatory powers originally sought by Attorney General Yosef Harish or his predecessor, Yitzhak Zamir, who was replaced after demanding a full-scale police investigation into the affair.

Harish was quoted by state-run Israeli television tonight as saying he did not know about the pardon compromise until after it was concluded, but he added, "There is no longer any point in continuing to investigate this affair."

The cover-up of the killing of the two captured Palestinian hijackers was one of two major scandals involving Israeli intelligence in recent months. The other was the arrest in the United States of Jonathan Jay Pollard, a U.S. Navy civilian intelligence analyst who pleaded guilty earlier this month to participating in an espionage conspiracy directed by Israeli officials.

There have been suggestions by senior Israeli officials that Yitzhak Shamir, who was prime minister at the time, knew about the cover-up but failed to take action to prevent it. Peres also was told of the cover-up by the three dismissed aides of Shalom more than six months ago, but he rejected demands that Shalom be suspended and investigated by police, according to official sources.

Herzog told reporters tonight that he issued the pardons -- which grant the four men immunity from prosecution -- because the Shin Bet affair was a "singular and exceptional case."

"I did this with the purpose of ending the witch hunt surrounding this affair and to avert additional serious harm to the security services," he said.

Praising the Shin Bet's record in combating terrorism, Herzog said, "A situation was created where Shin Bet people would have had to face investigation without the ability to defend themselves unless they disclosed security secrets of a most grave nature. In this situation, I saw before me first and foremost the need to protect the good of the public and the security of the country, and act as I acted."

Cabinet Secretary Yosi Beilin, in a television interview, acknowledged that there appeared to be no precedent for issuing a pardon before charges had been placed, but he said that "the situation where the head of the Shin Bet was faced with such an investigation is a unique situation."

Leaders of four opposition parties -- Shinui, the Citizens' Rights Movement, the communist Democratic Front for Peace and Equality and the leftist Progressive List for Peace -- promptly introduced parliamentary motions of no confidence in the coalition government headed by Peres, who is scheduled to rotate posts with Shamir on Oct. 25 under the coalition agreement. But there appeared little likelihood that the Labor-Likud coalition's narrow majority would unravel unless there were many Labor defections.

Some Labor Cabinet ministers, who were not present when the 10-member "inner cabinet" approved the compromise arrangement, questioned whether Herzog had the authority to pardon persons suspected of criminal acts but not convicted or charged.

Immigrant Absorption Minister Yaacov Tsur, a member of Peres' Labor Alignment, called the pardons a "moral blow" to Israel and Communications Minister Amnon Rubenstein said they were "a very undesirable precedent."

Chaim Zadok, a former justice minister and prominent member of Peres' Labor Party, criticized the pardons, saying, "For the Shin Bet, the lesson to be learned is that you can commit serious crimes. For the political echelon, the lesson is you can do anything you please and will not bear responsibility," The Associated Press reported.

The left-wing Mapam Party's Yair Saban said of the decision, "I'm afraid it's main aim is to cover the political figures involved in the scandal."

At the other end of the political spectrum, Geula Cohen of the rightist Tehyia Party, said the slain captives "were terrorists who tried to attack and kill dozens of people in a bus." Noting that they belonged to the Palestine Liberation Organization, she said, "We are killing them all over the world, and I hope we do more of it."

The presidential pardons came as an surprise; senior Cabinet ministers had appeared resigned to having some sort of special inquiry into the alleged cover-up of the beating deaths of the two Arab prisoners, who died after security forces took them off a hijacked bus in the Gaza Strip on April 12, 1984. The Army originally said the two had been killed when troops assaulted the bus they had hijacked, but a newspaper later published photos of them being led from the bus on foot.

Three former aides of Shalom had complained to Zamir that the Shin Bet chief, who was at the scene, ordered the handcuffed prisoners beaten to death and then directed an elaborate cover-up that involved suborning witnesses, falsifying evidence and perjury before two civilian investigating commissions and an internal Shin Bet disciplinary court.

As Harish met with senior Cabinet ministers late last night, the only unresolved questions appeared to be how the inquiry commission's deliberations would be kept secret to safeguard operational procedures of the Shin Bet and whether the probe would reach the political level, including the prime minister's office.

Cabinet Minister Ezer Weizman has suggested that Shamir was aware of all of the events surrounding the beating deaths and tacitly approved a cover-up. Several Israeli newspapers have said Shalom has a letter from Shamir containing approval of a cover-up and that the Shin Bet chief had planned to use it as a basis of his claim that he had official approval of his actions.

Shamir has not said whether he approved of the handling of the case, saying only that he "knew what a prime minister had to know." He has repeatedly said that he was opposed to any inquiry whose findings would be made public.