The two authoritarian rulers shook hands and toasted each other over a gala dinner.

But underneath the smiles and ceremony of Kim Jong Un's first meeting with Russian President Vladimir Putin on Thursday lies what analysts say is the real significance of the latest foreign trip by North Korea's young dictator: a stark message to President Donald Trump that talks with the United States are not the only game in town.

North Korea has for months been negotiating with the U.S. — ostensibly toward the goal of denuclearizing the Korean Peninsula. Trump left his first meeting with Kim in 2018 saying the pair had a "special bond."

However, Kim's last summit with Trump in February broke down without agreement. Negotiations between the two sides have since stalled, and it appears they still disagree about what "denuclearization" actually means.

And meeting Putin is partly Kim's way of signaling to Trump that he "can shop around for a deal," according to Robert Kelly, a professor of international relations at South Korea's Pusan University.

"Trump, as is his wont, has turned the engagement with Kim into an all-encompassing personal psychodrama, and the U.S. public and media drank that Kool-Aid," Kelly said. "Kim Jong Un is now happy to talk to anyone."

The North Korean dictator's overriding aim may be to protect his family's dynastic rule against regime change, experts believe. But Kim is also keen to ease the international sanctions that are squeezing his country's poor economy.

After years of isolation, Kim has appeared more eager to reach out in recent years, partly because he has achieved the ultimate bargaining chip: an intercontinental ballistic missile theoretically capable of carrying out a nuclear strike on the U.S. mainland.

This isn't all about Washington. As well as the two meetings with Trump, there have been four summits with Chinese President Xi Jinping and three more with South Korea's Moon Jae-in.

Now, with the U.S. talks going nowhere, the North Korean ruler is turning to Russia, to see what Putin can offer but also as a message to the other players.

"There are a number of reasons for the trip, and one of them is to show the U.S. that they are not the only game in town," according to Tom Plant at the Royal United Services Institute, a London think tank. "The U.S. will clearly be watching very closely for any outcomes."

Putin met Kim at the Far Eastern Federal University campus on Russky Island. Alexey Nikolsky / AFP - Getty Images

Thursday's summit took place on Russky Island, near Russia's far-eastern port of Vladivostok.

There was substance, as well as symbolism. The two countries share a tiny, 11-mile land border, and Putin wants to build a gas pipeline and rail routes through the North and into South Korea.

Putin would prefer not to have another nuclear power on his doorstep. But while that is a reality, experts say he would at least like to be seen as a major power broker in negotiations currently involving the Koreas, the U.S. and China.

"We talked, of course, about the situation on the Korean Peninsula," Putin said during a break in the talks, Reuters reported. The Russian president said he would be willing to share details of the discussion with Trump, claiming that "there are no secrets" in this process.

The summit, he hoped, would "help better understand what should be done to settle the situation on the Korean Peninsula".

But what Putin is actually willing or able to achieve is unclear. He reiterated North Korea's mantra that the country is prepared to work toward denuclearization but needs strong security guarantees to do so.

Putin and Kim share a toast. Alexey Nikolsky / AFP - Getty Images

Putin did not specify what guarantees these might be, and his comment does not address the problem that North Korea and the U.S. still seem to have conflicting definitions about what denuclearization means.

Washington wants complete, verifiable and irreversible dismantlement, or CVID, of North Korea's nuclear arsenal. Most experts see this as a pipe dream — why would Kim throw away four decades of work, and with it, the only real guarantee against regime change?

For its part, Pyongyang has suggested denuclearization might involve ending the American nuclear umbrella that protects South Korea and Japan, or even the removal of U.S. troops from the region.

According to Plant, Putin talking to Kim is an attempt to diminish the importance of U.S. sanctions and therefore U.S. global influence.

"Maybe Russia's interests are best served by trying to ... reduce the effectiveness of international sanctions in general so they're not seen as legitimate or effective in general," he said. "In the grand scheme of things, where are Russia's interests? I think they lie around this sanctions issue."