Hun Sen stays in power because Hanoi likes him.
You are right.
Hun sen can play his policy game now, to show that Cambodia is independent state. It is nothing wrong when in this moment, Cambodia has good relationship with other superpower in the world, with Japan, China and USA.
Hunsen was very young when he was division commander of Khmer Rouge, but he has escaped to Vietnam when he joined in to invasion in to border of Vietnam. After fighting he realized that there is suicide attack. He joined to Heng Sonrin army.
Hun Sen has finished his study in Vietnam, he has awarded Ph D for politic in Ho Chi Minh Policy Institute in Hanoi, before he was taken in to his position PM of Cambodia. What he does now, is similar to what Vietnam do.
After incident in Asean summit in Phnom Penh, he has droped to Hanoi, and he has the speechs with Vietnamese war veterans in Hanoi, he speaks Vietnamese like ordinary Vietnamese.