Mattis, in Hanoi, thanks Vietnam for backing North Korea sanctions

Just days before the 50th anniversary of the Tet Offensive -- a key event of the Vietnam War -- U.S. Defense Secretary Jim Mattis arrived in Hanoi and commended Vietnam for supporting U.N. sanctions against North Korea.

Mattis also voiced optimism that, despite a history of conflict, Washington and Hanoi can develop stronger defense ties.

"They've stepped up and aligned themselves with U.N. sanctions," Mattis told reporters earlier, while flying from Jakarta, Indonesia, where he held high-level talks and received a close-up look of Indonesian commandos displaying their combat skills.

The Tet Offensive was launched in 1968 and resulted in a major loss for the communist North Vietnamese, but it also cast doubt among the American public on whether the U.S. could win the war.

Mattis underscored that the Vietnam War was “in our past,” adding that it will have no impact on current relations. The Pentagon chief did not serve in that war.

Vietnam is a crucial player in disputes with China over territorial claims in the South China sea given the country’s proximity, Mattis noted. The country also fought a border war with China in 1979.

"Because of the coastline they have and the position they occupy, they are going to be a foundation for any kind of prosperity" in the region, which is one reason to push now for closer defense relations, he said.

During his visit, Mattis plans to meet with representatives of a Pentagon organization, the Defense POW-MIA Accounting Agency, which searches for service members from the Vietnam war that are still missing. The war ended in 1975.

Following his stop in Vietnam, Mattis will fly to Hawaii where he will conduct talks with U.S. commanders and meet with his South Korean counterpart to discuss the looming nuclear threat in the Hermit Kingdom.

Before he left Jakarta on Wednesday morning, Mattis was presented with a demonstration of counter-terrorism skills by an Indonesian commando group that included hand-to-hand combat, chopping of the heads of live snakes and drinking their blood, among other exotic moves.

Mattis said in Jakarta that he hoped the U.S. could develop closer ties to the Indonesian military.

The Associated Press contributed to this report. 

Benjamin Brown is a reporter for Fox News. Follow him on Twitter @bdbrown473.