Aids is the leading cause of death in military and police forces in Africa, according to research.
HIV/Aids has decimated African populations
A study carried out by scientists in Nigeria says Aids could now be responsible for more than half the deaths in these services.
The researchers interviewed about 500 Nigerian naval officers.
Almost a third of those interviewed admitted having had sex with prostitutes, with nearly a half saying they did not use a condom.
Many knew how HIV was transmitted, but more than 50% thought a cure for Aids was already available.
The research was published in the Biomedcentral Public Health Journal.
In further work the scientists also reviewed much of the available data on HIV in the military.
According to the scientists, this type of lifestyle - being posted away from partners for long periods of time - encourages soldiers to have sex elsewhere and has lead to HIV being a major problem in many African countries.
Discussions are already under way between naval authorities and doctors to address the problem.
Tackling the issue in the military, the authors say, is one of the most realistic ways of controlling the spread of HIV across Nigeria.
The country has one of the world's highest numbers of people living with the Aids virus, according to Nigeria's health minister.
Eyitayo Lambo has said that some 2.3m Nigerians had already died from Aids, while 3.8m were HIV positive.
Only South Africa and India have more people infected with HIV.