President Chun Doo Hwan said yesterday that President-elect Ronald Reagan has shown an encouraging willingness to understand the special problems of U.S. allies such as South Korea.

In an interview, Chun contrasted Reagan's attitude with what he described as an American habit of punishing and weakening allied countries whose actions "do not meet with your approval."

Although he was not specific, Chun apparently was referring to the Carter administration's repeated criticism of South Korea's handling of dissidents and opposition politicians.

"Promises made by candidate Reagan during the campaign contained his willingness to understand the realistic situation in which United States allies are placed," Chun said. "That is very encouraging."

In the past, he said, U.S. policymakers have tended to judge allies from the perspective of a prosperous, serene country never invaded by foreigners, while his country faces "a battle for survival" with communist North Korea.

"From that perspective, you make judgments about your allies and act upon those judgments or exercise sanctions because of certain things that do not meet with your approval," Chun added.

"What may happen is a serious weakening of America's allies. Vietnam and Iran were once allies of the United States and they have been taken over after a serious weakening of their structure."

Chun's remarks were in the familiar pattern of the the government's contention that it cannot permit civil liberties to flourish for fear that it would encourage North Korea, which invaded this country in 1950, to strike again.

Since taking control in a military crackdown last May 17, Chun's government has blacklisted many former politicians, barred demonstrations and written criticism of the government, and arrested many opposition figures.

In the most celebrated case, opposition leader Kim Dae Jung was convicted of sedition and faces a death sentence. If the Supreme Court confirms the conviction, Chun could spare his life by commuting the sentence.

Chun refused to comment on Kim's case, saying it is still before the court.

The incoming Reagan administration has joined the Carter administration in warning South Korea that relations between the two countries would be strained if Kim is executed. A Reagan aide reportedly has warned an execution would cause "incalculable harm" to the relationship.

Chun, questioned about that, at first appeared to deny any such message had been sent by Reagan's advisers. Speaking through an interpreter, he said at first, "There has been no communication to that effect."

At that point, one of Chun's advisers, Kim Kyong Won, corrected the translation to say, "I know of no direct communication to that effect." Chun said it would not be in keeping with "common practice" for an incoming administration not yet in power in Washington to make such statements.

Chun, 49, is a former general who rose quickly to power after the assassination last year of president Park Chung Hee. He was elected to an interim term as president in September and is preparing to run for a full term next spring. He presides over a country beset with economic recession and internally divided between his military-backed government and those who want faster movement toward democracy.

Emphasizing his country's ties with the United States, Chun pointed out that American troops fought for South Korea in the 1950s and that South Korean troops fought alongside Americans in Vietnam, where he served as an officer.

"Our relationship is sealed in blood and it is not what you build overnight," Chun said. "We have a longstanding friendship . . . that grows healthier as the years progress. We will get along better because it has been maintained for a long time. To that end, I will devote my best efforts."