Senators of both parties, repeatedly citing the controversy surrounding former White House aide Michael K. Deaver, praised legislation yesterday that would force former high-ranking federal officials such as Deaver to give up their contracts with foreign clients.

Two Reagan administration officials, however, told the Senate Judiciary Committee they have reservations about a measure sponsored by Chairman Strom Thurmond (R-S.C.) that would impose substantial restrictions on lobbying by all federal employes, including members of Congress, after they leave government.

"The Mike Deaver affair is the latest in an escalating series of ethical problems to beset our government," said Sen. Howard M. Metzenbaum (D-Ohio). "Deaver followed a well-worn path pursued by both Democrats and Republicans alike . . . . The plain truth is that Washington has become a sinkhole of influence peddling."

Sen. Paul Simon (D-Ill.), noting reports that Deaver's firm is being paid nearly $2 million a year by Saudi Arabia and South Korea, said, "Let's be candid. Is he getting that because he knows so much about Saudi Arabia or South Korea? He's getting it because of access . . . . That simply isn't right."

On Monday, Deaver called for an independent counsel to investigate allegations that he may have violated conflict-of-interest laws since resigning as White House deputy chief of staff 12 months ago and setting up a consulting firm that has millions of dollars in contracts with foreign and domestic clients. The Justice Department is expected to begin a preliminary investigation soon that could lead to such an outside probe.

The Thurmond bill would impose an immediate lifetime ban on senior federal officials -- including Cabinet members, agency heads and top White House aides -- representing foreign interests after leaving government. Former employes currently representing foreign interests would have to give up those clients.

The measure would also bar all federal employes and members of Congress from lobbying the federal government on any issue for one year after resigning, and from representing foreign clients for two years. It carries criminal penalties of two years in prison and $250,000 in fines.

Thurmond said the bill would "terminate violations of public trust" and stop "very high-ranking federal officials from marketing their access and influence for private gain."

Other Republicans, including Sen. Arlen Specter (R-Pa.), also called for strengthening the ethics laws.

But Deputy Assistant Attorney General John C. Keeney said there were "potential constitutional pitfalls" with parts of Thurmond's bill, particularly the lifetime ban on representing foreign interests. He said the courts might strike that down as restricting a person's "right to make a living."

Keeney said there was "no evidence" that conflict-of-interest violations "are a significant law-enforcement problem." From 1980 to February 1985, he said, U.S. attorneys dropped 45 of 50 such cases without bringing charges, and the Justice Department declined to prosecute 51 other such cases.

Sen. Joseph R. Biden Jr. (D-Del.) questioned this record, saying that "the Justice Department is making a judgment that although you can make a technical case, juries . . . will not convict." But Keeney said that current law does not prohibit certain "conduct that you and I may not be proud of."

David H. Martin, director of the Office of Government Ethics, who referred the Deaver case to the Justice Department, said that "we cannot support the all-encompassing types of restrictions which this proposal contains." He said the bill could have the effect of "stifling the legitimate career aspirations of the majority of government workers."

Metzenbaum, however, said it would affect those "whose only interest in government service is the pot of gold at the end of the rainbow."

Thurmond's bill is more sweeping than current law, which bars officials from representing clients before their former agencies for one year, and from ever lobbying on issues in which they were personally and substantially involved. Keeney said the law should be broadened to bar former officials from skirting the ban on contacting their former agencies by giving clients "behind the scenes advice" on how to deal with those agencies.

A similar proposal by Sen. David L. Boren (D-Okla.), which has 90 House cosponsors, would bar former top officials from representing foreign clients for five years.