Good question. Having lived in both Vietnam and Brazil, I have often thought about this. I would say that the answer is that they, like many European countries, put an emphasis on public good/safety over individual rights.
Vietnam is a much poorer country than Brazil, yet the murder rate is much lower (1.7 per 100,000 pop compared to 25.2 in Brazil and 6.2 in the US). I can ride a motorcycle anywhere in Vietnam and feel pretty safe. I can't say the same for Brazil. So, imagine that. A country that was a dangerous war zone in my parents' generation is one of the safest countries when it comes to violent crime.
Pro gun people often point to Vietnam as an example of how the people can fight off a standing army. But maybe it would surprise them to learn that owning guns is mostly not allowed in Vietnam. All those AKs from the war? Had to give them up. What happens if you get caught with a gun? It's highly illegal. You go to jail. If you get caught trafficking guns? You'll get the death penalty. As far as I know, exceptions can be made for people who live in rural areas and use guns for hunting. But here, we would be talking about bolt-action rifles and shotguns.
Religion. Vietnamese are mostly Buddhist and Catholic. Not much to say here. But beliefs about karma certainly exist. If you kill somebody, you dishonor all of your family and your ancestors.
Urbanization/family/people living close together. All things that would make a person not want to obtain an illegal gun. Own or know about an illegal gun, and you risk people around you being jailed.
So that's a little of how it is there. The rule of law is strong there. There are no favelas that the government are afraid to go into. If people really want to be able to shoot guns, they can join the People's Army Reserves.