Interesting example - because they are. The military is responsible for a lot more research than is immediately obvious. All you have to do is come up with some plausible military use (offense or defense), and you have a chance for funding.
I've seen projects with just the barest hit of possibly being militarily related get funded by the military.
I get the feeling the military knows they are overfunded, and they try to make up for the lack of funding in other places.
Or perhaps the military likes being over funded - so when they need it, they have it. But the rest of the time they can fund other things (and presumably cancel them in an emergency).
If the construction, deployment, staffing, etc was pointed towards space research and exploration, we'd be able to push forward all sorts of projects.
The space shuttle, for instance, persisted not for the scientific or technical advances, but that it sent money to lots of political constituencies, which alone made it viable. The Hubble, while giving us spectacular images, was still horribly overpriced and NASA ended up paying for it twice over (once to send it up and twice to send the shuttle after it).
There wasn't a lot of opposition to the shuttle and the ISS from within NASA (for 'eating up the budget') because they were aware that budget only existed because of these high-value items. They might have liked to have the money for other things, perhaps, but political money doesn't work that way.
At least here in Australia, a common comment on something like this is that we shouldn't spend money on this sort of thing when there are people starving and dying in the third world. Then the typical comments on, say an article about, the plight of the poor in the third world are critical of throwing money abroad when we have problems of our own at home. Then the typical comments on those problems (say, gap in life expectancy between that of the Aboriginal population and the average) find another excuse.
It frustrates me too. I'd love to see military budgets (as one example) plowed into aggressive space research and exploration (as well as third world problems) and uniting the planet.
Maybe the Great Filter of the Fermi Paradox is just the tendency of the masses towards selfish, lazy, basic instinct-driven behaviour.