And in an impoverished country where every public institution has crumbled, they have become heroes in the steamy coastal dens they operate from because they are the only real business in town.

"The pirates depend on us, and we benefit from them," said Sahra Sheik Dahir, a shop owner in Harardhere, the nearest village to where a hijacked Saudi Arabian supertanker carrying $100 million in crude was anchored Wednesday.

These boomtowns are all the more shocking in light of Somalia's violence and poverty: Radical Islamists control most of the country's south, meting out lashings and stonings for accused criminals. There has been no effective central government in nearly 20 years, plunging this arid African country into chaos.

Life expectancy is just 46 years; a quarter of children die before they reach 5.

But in northern coastal towns like Harardhere, Eyl and Bossaso, the pirate economy is thriving thanks to the money pouring in from pirate ransoms that have reached $30 million this year alone.

"There are more shops and business is booming because of the piracy," said Sugule Dahir, who runs a clothing shop in Eyl. "Internet cafes and telephone shops have opened, and people are just happier than before."

In Harardhere, residents came out in droves to celebrate as the looming oil ship came into focus this week off the country's lawless coast.

Businessmen gathered cigarettes, food and cold bottles of orange soda, setting up kiosks for the pirates who come to shore to resupply almost daily.

Dahir said she even started a layaway plan for them.

"They always take things without paying and we put them into the book of debts," she told The Associated Press in a telephone interview. "Later, when they get the ransom money, they pay us a lot."

Residents make sure the pirates are well-stocked in khat, a popular narcotic leaf, and aren't afraid to gouge a bit when it comes to the pirates' deep pockets.

"I can buy a packet of cigarettes for about $1 but I will charge the pirate $1.30," said Abdulqadir Omar, an Eyl resident.

While pirate villages used to have houses made of corrugated iron sheets, now, there are stately looking homes made of sturdy, white stones.

"Regardless of how the money is coming in, legally or illegally, I can say it has started a life in our town," said Shamso Moalim, a 36-year-old mother of five in Harardhere.

"Our children are not worrying about food now, and they go to Islamic schools in the morning and play soccer in the afternoon. They are happy."

The attackers generally treat their hostages well in anticipation of a big payday, hiring caterers on shore to cook spaghetti, grilled fish and roasted meat that will appeal to Western palates.

And when the payday comes, the money sometimes literally falls from the sky.

"The oldest man on the ship always takes the responsibility of collecting the money, because we see it as very risky, and he gets some extra payment for his service later," Aden Yusuf, a pirate in Eyl, told AP over VHF radio.

The pirates use money-counting machines — the same technology seen at foreign exchange bureaus worldwide — to ensure the cash is real. All payments are done in cash because Somalia has no functioning banking system.

"Getting this equipment is easy for us, we have business connections with people in Dubai, Nairobi, Djibouti and other areas," Yusuf said. "So we send them money and they send us what we want."

Despite a beefed-up international presence, the pirates continue to seize ships, moving further out to sea and demanding ever-larger ransoms. The pirates operate mostly from the semiautonomous Puntland region, where local lawmakers have been accused of helping them and taking a cut of the ransoms.

For the most part, however, the regional officials say they have no power to stop piracy.

Meanwhile, towns that once were eroded by years of poverty and chaos are now bustling with restaurants, Land Cruisers and Internet cafes. Residents also use their gains to buy generators — allowing full days of electricity, once an unimaginable luxury in Somalia.

There are no reliable estimates of the number of pirates operating in Somalia, but they number in the thousands. And though the bandits do sometimes get nabbed, piracy is generally considered a sure bet to a better life.

NATO and the U.S. Navy say they can't be everywhere, and American officials are urging ships to hire private security. Warships patrolling off Somalia have succeeded in stopping some pirate attacks. But military assaults to wrest back a ship are highly risky and, up to now, uncommon.

Online Public Information File

Viewers with disabilities can get assistance accessing this station's FCC Public Inspection File by contacting the station with the information listed below. Questions or concerns relating to the accessibility of the FCC's online public file system should be directed to the FCC at 888-225-5322, 888-835-5322 (TTY), or fccinfo@fcc.gov.