A missing key has been found to a story that won't go away -- a story that we wrote during the 1980 presidential campaign but that then-President Jimmy Carter swore never happened. We reported, and Carter angrily denied, that he was planning a military attack on Iran as an "October surprise" on the eve of the election.

The missing evidence has been uncovered by John Barron, a former intelligence officer specializing in Soviet affairs who is now a senior editor for Reader's Digest. He revealed the evidence as part of his investigation of the John Walker spy case. After digging through exhaustive files and interviewing Walker at length, Barron wrote a book about the Walker espionage ring.

From Barron's book, "Breaking the Ring," and other sources now available, here are the bare bones of the Carter caper:

The story began in April 1980, with the bollixed attempt to rescue American hostages from Iran. "Humiliated and seemingly impotent, the Carter administration laid plans to redeem itself in the eyes of the electorate by mounting a much larger attack upon Iran," relates Barron.

This has been confirmed by Carter's national security adviser, Zbigniew Brzezinski. The day after the disaster in the desert, Brzezinski states, "I convened a meeting in my office, on the instruction of the president, to plan another rescue mission."

Brzezinski argued not only for a rescue raid but for a larger, punitive military assault. "The actions that made the most sense to me," he recalls, "involved seizing Kharg Island, Iran's main oil-export facility, and imposing a naval blockade, possibly combined with air strikes."

Barron reports that "preparations proceeded in unprecedented secrecy." Yet the Soviets were fully aware of Carter's moves. Our National Security Agency intercepted some secret Soviet intelligence cables; it was clear from these intercepted messages that the Kremlin knew what was happening. They even had knowledge of the timing; some cables referred to the impending U.S. action in Iran as an "October coup."

How did the Kremlin know about Carter's supersecret preparations? Barron has learned the answer; he reports that the Walker spy ring delivered the Pentagon's secret codes to the Soviet Union. So in 1980, the Soviets were able to decipher the Pentagon's most secret messages. This provided them, in advance, with the details of Carter's October surprise.

Barron reports that the Soviet Union rushed 22 full divisions to the Iranian border. He concludes tersely: "American reconnaissance detected the poised Soviet formations. With their discovery, a horrendous specter immediately became apparent:

"The moment the U.S. raiders land . . . Soviet airborne troops quickly surround the Americans, while Soviet armored divisions hurtle across the border. President Carter now must choose. He can let the vastly outnumbered American force surrender or be annihilated. Or he can resort to nuclear weapons and risk precipitating World War III.

"Prudently, Carter canceled the raid."