The Somali pirates are having a bad year, but they are still winning. This month, attacks are down over 70 percent compared to last year. This year, only 20 percent of attacks have been successful, compared to 40 percent last year. While there have been more attacks this year (142 so far, compared to 122 for all of last year), the number of attacks per month has sharply fallen of late. Meanwhile the number of foreign warships patrolling the coast has gone from 14 at the beginning of the year, to 31 (from 17 countries) now. Keeping warships at sea is expensive. The patrol off Somalia is costing about half a billion dollars a year. Then there are about a dozen maritime patrol aircraft and UAVs, most operating out of Djibouti (just to the west of northern Somalia). More UAVs are operating off some of the warships. And most of the destroyers have at least one helicopter on board. All the land based aviation and spy satellite use is costing over $100 million a year.
The warship patrol has been quick to adapt to the pirate tactics (which are always changing), and this is what is making it more difficult to capture ships. There are two 800 kilometer long secure shipping corridors (one east bound, one west bound), through the Gulf of Aden. These corridors are patrolled, and, for maximum security, ships can choose to move through with the escorted convoys that make the run regularly. The anti-piracy task force flies long range air patrols way out over the Indian Ocean, to look for pirate mother ships. As a result, long range (over a thousand kilometers from the coast) pirate attacks have fallen sharply.
However, 80 percent of the attacks defeated do not involve any of those foreign warships. The merchant sailors, and the ship owners, have adopted defensive measures that have become remarkably successful in defeating pirate attacks. For the captain himself, the best defense is knowing what speeds and maneuvers his ship can use to keep the pirates away. Larger ships can create dangerous wakes for the pursuing speedboats, by zig zagging. Captains also have to learn how fast their ship can accelerate to escape oncoming speed boats. Normally, captains are more skilled at moving their ships at slower (more economical and safer) speeds. Putting the pedal to the metal and hot roding around the high seas is not normally part of their skill set. But that's how you avoid getting hijacked by pirates. Captains are learning, and so are their crews.
Ship captains are organizing and drilling their crews on things that can be done to keep the pirates from getting aboard. This ranges from stringing barbed wire around likely boarding points, to practicing the use of fire hoses and other tools (like long poles) to keep the ladders or grappling hooks from enabling the pirates to get aboard. These drills build confidence in the ability of the crew to defend their ship.
The sailors also now keep track of where the nearest warships are, and prepare a "safe room" (an area of the ship the crew can barricade themselves in, until help arrives.) This includes providing emergency communications in the safe room. All this takes advantage of the fact that the pirates cannot take control of the ship unless they have the crew. Usually this comes down to barricading the crew in the engine compartment. If the crew prepares for that eventuality (having a radio available to contact the warships, along with water, food and medical supplies there), just getting everyone into the engine room when it appears that the pirates are going to get on board, means that the pirates will be caught between the crew they cannot reach, and the approaching warship that can certainly reach the pirates.
But with all that, the pirates are still going to extort over $70 million from the shipping companies this year. In addition, the shipping companies, and the countries they come from, are spending several billion dollars to deal with the problem (insurance, danger pay, warship expenses). The ships are getting through, with minimal interruption, but the pirates still have an incentive to go after them.