Image copyright Reuters Image caption Vietnam's navy gave Mr Obama a guard of honour - now they will have access to US defence technology

As US President Barack Obama announced the lifting of the decades-long embargo on sales of lethal weapons to Vietnam, he seemed at pains to explain the decision "was not based on China or any other considerations".

Yet his mention of China reveals some of the greatest security concerns brewing in Hanoi.

Since a brief but bloody border war in 1979 that cost thousands of lives, Vietnam-China relations have been bumpy to say the least. From being Vietnam's biggest ally, ironically, in the war against the United States, China has increasingly been seen as a dominant, and at times, threatening neighbour.

Recent tensions in the South China Sea have added to the growing mistrust. Vietnam protests against what it sees as excessive Chinese maritime claims and supports the court case brought against China by the Philippines. Not only does China's growing assertiveness in the area challenge Vietnam's sovereignty, it could greatly affect its fishery, oil and gas activities, too.

Media playback is unsupported on your device Media caption President Obama said lifting the arms embargo would remove "a lingering vestige of the Cold War"

It is no secret that Vietnam is trying to boost its maritime defensive capability. Its largest arms contract to date with a foreign country was the $2bn purchase of six kilo-class submarines from Russia.

A large number of patrol and missile ships and fighter jets have also been purchased from Russia, as Vietnam's military spending more than doubled between 2004 and 2013. It is now the eighth largest importer of weapons in the world.

In the last few years Hanoi has also sought to expand its military ties with other countries, too, forging partnerships with Spain, the Netherlands and Israel to name a few.

Now the arms embargo has been lifted, Vietnam will be able to access the latest technologies and equipment the US military has to offer.

Beijing's new South China Sea islands

High hopes for Obama visit

But many think it will be a while before Vietnamese-manned F-16s are seen patrolling the East Sea, which is how the Vietnamese refer to the South China Sea.

Before the Obama visit, senior Vietnamese defence officials repeatedly said they had no major plans to buy weapons from the US. Instead, they were looking to transfer technology and perhaps boost patrol capability.

In the immediate future this is unlikely to change, especially because of the US precondition that the sale of arms will depend on Vietnam's human rights commitments and will be considered case by case.

Alongside this, of course, is the fact that Vietnam doesn't have much money to spare, given its economic problems.

But the US announcement is being seen as a powerfully symbolic gesture - "proof that the US-Vietnam relationship has fully normalised", as Vietnamese President Tran Dai Quang put it.

His counterpart seemed to agree, saying that his visit to Vietnam showed that "hearts can change and peace is possible".