The ruling Democratic Party candidate in South Korea's upcoming presidential election signaled alarm at Japan on Wednesday, saying he is "of course opposed" to the idea of a military alliance among the United States, South Korea and Japan.

Citing an ownership dispute with Japan over South Korean-controlled islets in the Sea of Japan, Lee Jae Myung said at a media event, "Is Japan a perfectly friendly state that can be trusted at all times?"

Lee Jae Myung, the presidential candidate of South Korea's ruling Democratic Party, speaks during a debate in Seoul on Nov. 10, 2021. (Kyodo) ==Kyodo

Lee, who was governor of Gyeonggi Province until last month, has previously expressed his distrust of Japan, which ruled the Korean Peninsula from 1910 until the end of World War II in 1945.

Ties between the two countries have soured considerably in recent years over wartime labor compensation and other issues stemming largely from Japan's 35-year colonial rule.

The United States has forged a defense alliance with South Korea and Japan, its key security partners in East Asia. But there is no alliance between the two neighbors.

Lee said that while sufficient preparations are necessary against North Korea, he thinks a tripartite military alliance involving Washington, Seoul and Tokyo "would be extremely risky" when one looks at Japan taking a "vague stance" toward territorial issues and its past "invasion" of the peninsula.

In an interview with a local newspaper, Lee said South Korea "needs to be prepared in the event Japan's dream of continental expansion erupts militarily."

On where South Korea should position itself amid the Sino-U.S. rivalry, the Democratic Party nominee said at Wednesday's event that South Korea does not need to abandon its "cooperative ties" with China even while it strengthens its alliance with the United States.

"Properly balancing" between the two powers will put South Korea "on the path toward prosperity," Lee added.

In the March election, Lee is expected to face the main opposition People Power Party nominee, former Prosecutor General Yoon Suk Yeol. The winner will take over from President Moon Jae In, who ends his single five-year term in May.