That's not really a sensible solution withnail. Somalia's president was propped up alternately by the Russians and Americans until the end of the Cold War, when both sides decided they weren't interested, so the people threw him out (Mohamed Siad Barre, I think it was). It was aid that kept Barre in power. Giving aid to anyone there now is a waste of time, they'll use it to buy more guns (the ransom money could be thought of as a sort of aid, I suppose).

The alternative is organising outright conquest and occupation, the way we British used to in the good old days. I hear most of the pirates opeate out of Puntland, which used to be British Somaliland. At independence, the British and Italian (?) portions were reunited. After the fall of Barre and the consequent anarchy, a more or less stable government was established in Puntland, which wanted recognition but was refused it. I think the piracy came later - if the world had accepted the division of Somalia on the old frontiers, some of the problems might have been avoided. But that would still leave Somalia, where efforts to prevent pro-Islamist warlords becoming the de-facto government have ensured that anarchy and chaos continues, because Ethiopia and its Somalian friends are not strong enough to win, but Western support prevents them being entirely beated.

Not an easy one to solve.