The unearthing of a diplomatic cable to Washington from the U.S. Embassy in Tehran describing Sen. Edward Kennedy's visit in May 1975 casts a shadow on the senator's description of the shah's regime as "one of the most violent in the history of the world."

The routine cable, addressed to then secretary of state Henry Kissinger but which he probably never saw provides a cloudy backdrop to Teddy Kennedy's latter-day verbal assault on the toppled shah. Kennedy not only accepted, gratis, an Iran Air Boeing 727 "for travel within Iran," but he was also "provided rooms at the best hotels in Tehran and Isfahan, lavish hospitality for all 12 members of [his] party" and police escorts "usually offered only to visiting heads of government."

Paragraph four of the diplomatic cable barely touched on the issue that, 4 1/2 years later, Kennedy singled out in his Dec. 2 verbal assault on the shah -- the matter of human rights. It said that during the senator's 80-minute private session with the shah and talks with other top officials, Kennedy "also touched lightly on human rights issues." His "basic themes" were the dangers of a Mideast arms race and the need for greater "international cooperation to redress economic inequities."

The contrast between Kennedy's acceptance of the shah's "lavish hospitality" ("imperial court treated senator as . . . front-runner for presidency") and his sudden recollection last month of the shah's "most violent" regime has not been unique among politicians. Others, possibly trying to milk votes out of the Iranian tragedy, have done the same.

After years of relative silence, for example, Sen. Howard Baker, the Senate Republican leader and a presidential contender, has criticized U.S. policy toward Iran, saying on Jan. 7 -- two weeks before the Iowa caucuses -- that he would "stay away from the business of shoring up a dictator."

More pointed has been the about-face in Moscow. On Dec. 5, two days after Kennedy's attack on the shah, Tass called the shah a "criminal." Referring to U.S. assistance that helped restore the shah to his throne in 1953, Tass asked: "For was not international law also flouted by the actions of the U.S. special services [meaning the Cntral Intelligence Agency], which organized the overthrow of the legitimate government in Iran and foisted the shah's lawlessness on the Iranian people [for] a quarter of a century?"

For 15 years before that knock at the shah, Moscow nurtured him with a benign public attitude and a plethora of economic goodies. On Nov. 18, 1963, Soviet President Leonid Brezhnev said in a speech during a state visit by the "criminal" and his wife that "I would like to stress the distinguished and respected visitors will be received in our country with joy and hospitality."

In words that gushed with affection, the late Soviet leader Nicolai Podgorny on Nov. 18, 1974, at the end of another state visit from the shah, praised "the strengthening of trust" with the "criminal" of five years later.

Such reversals of field following political upheavals in foreign countries have less to do with facts than with the hope of reward. In Kennedy's case, he was judged guilty of overkill immediately after his Dec. 2 outburst and was widely criticized. The uncovering of the June 3, 1975, diplomatic cable seems to confirm that criticism.

It was signed by then ambassador Richard Helms. Helms had arrived in Tehran from Washington during Kennedy's last day there and, other than having Kennedy to dinner that evening, took no part in the visit and did not write the routine cable describing the senator's visit. Messages from a U.S. embassy are invariably signed with the ambassador's name.

The special treatment accorded Kennedy by the shah, with no indication of on-the-scene remorse by Kennedy, included his 80-minute audience with the shah; two sessions with "representative" groups of students at the University of Tehran; a dinner at the house of Ardeshir Zahedi, then Iran's ambassador to the United States, "hosted by his daughter, Princess Mahnaz [the shah's granddaughter] to which the cream of Iranian establishment was invited."

Kennedy's Boeing 727, courtesy of Iran Air, took him on a two-day, all-points sightseeing tour around the country, including over-flights of the Persian Gulf and the Straits of Hormuz -- that critically important passage for the West's and Japan's oil supplies that the shah protected with U.S. help for a quarter of a century.

The last paragraph of the cable from Tehran noted the visit has been Kennedy's first. It gave him an "excellent opportunity to evaluate the situation as it really is and to balance some of the negative impressions about Iran" that Kennedy appeared to bring to Iran with him.

Until Dec. 2, 1979, that summing up seemed to hit the nail on the head.