Baidoa, Somalia (CNN) The murderous al Qaeda affiliate al-Shabaab is making millions of dollars each year by exploiting foreign aid money sent to Somalia by the very western nations who are trying to eliminate the terror group.

A CNN investigation has revealed how money given directly by the United Nations to people displaced by conflict and famine is ending up in the hands of Africa's oldest terrorist organization.

Former members of al-Shabaab and Somali intelligence agents said the terror group is extorting thousands of dollars per day through road blocks and taxes on merchants attempting to transport food and supplies to sell to internally displaced people in towns where they are concentrated.

People who have fled their homes and are living in a sprawling camp in the central Somali city of Baidoa are screened by the UN and issued cash cards that the UN tops up with around $80 to $90 each month, enabling them to buy essentials from local merchants.

UN officials say this direct payment system will avoid distorting local markets by flooding them with free food, and relieve the UN of the burden of running food convoys that are vulnerable to attacks and theft.

Businessmen now truck food bought on the open market to places like Baidoa, where internally displaced people (IDPs) arrive every day. But they must pay al-Shabaab, which controls the main road into the town, to move their goods.

Former members of the terror group and Somali intelligence agents said that tolls taken from trucks and other vehicles at just two al-Shabaab roadblocks on Somalia's busiest road raked in thousands every day. The UN has estimated that a single roadblock generated about $5,000 per day on the road to Baidoa.

'Tax' collectors

Speaking at a secret location on the outskirts of Baidoa, a former zaqat (tax) collector for al-Shabaab, who was captured in a recent raid by agents from Somalia's National Intelligence and Security Agency, confirmed that the extraction of tolls at roadblocks was one of the biggest sources of money for al-Shabaab.

The two biggest sources were the road to Baidoa and the main artery which connects the capital Mogadishu with the agriculturally-rich Lower Shabelle region.

The gouging is more subtle today than it was in the early 1990s, when local warlords deliberately starved hundreds of thousands of Somalis in order to profit from international aid money. Scenes of mass death on the streets of Baidoa in 1992 provoked the United States to lead a multinational UN-backed military intervention in the same year.

270,000 internally displaced people now live in Baidoa.

In Baidoa back then, a truck known as the Death Bus collected around 100 bodies a day, all of them skeletal from starvation, from the dusty streets of the town every morning.

Aid organizations were so desperate to help that they paid warlords to permit access to starving victims. Until Western nations intervened, the warlords worked to sustain the famine in order to keep the aid money flowing into their coffers -- effectively exploiting desperate people to turn a profit.

Back then, organizations like the International Committee of the Red Cross had to pay for armed guards -- the ICRC spent $100,000 a week on protection in Mogadishu.

The money went into the hands of mere gangsters -- not international terrorist organizations, who are less forgiving when their debts go unpaid.

In 2018, if local merchants don't pay up, "they're captured and killed," said a former al-Shabaab fighter who collected tax for eight years and now works with Somalia's National Intelligence and Security Agency.

Newly arrived IDPs build shelters in Baidoa. The UN estimates there are now 2.1 million IDPs in Somalia, two-thirds of whom are children.

Speaking in a secret location in Baidoa, he explained how for every sack of rice delivered to the city by private merchants, al-Shabaab would cream off about $3 in tolls, taking nearly half the difference in the price of a sack that sells for $18 in Mogadishu and $26 in Baidoa.

On top of that the merchants are then forced to pay an annual tax to al-Shabaab -- even in towns and cities that are not under the group's control, like Baidoa and Mogadishu.

These allegations have been confirmed by the regional government and the president of the South West State of Somalia, Hssan Sheikh Ada.

Michael Keating, the UN's head of country, acknowledged the scam but said that most of the foreign aid still reached its intended destination.

"Unfortunately those in need, and those who are going to be targeted by humanitarian organizations to receive assistance, do become attractive for those trying to make money, and there will be all sorts of scams going on," said Keating, a veteran UN official with years of experience in Afghanistan and the Middle East.

"To deny it is happening would be wrong, but I think to take examples of it happening, and to say the whole response is like this, would be a gross misrepresentation of what is going on."

Forced to flee

The paying of "zaqat" isn't confined to road tolls and taxes on businessmen. Ordinary Somalis have to pay an annual tax to the al Qaeda group which was behind terror attacks on the US embassies in Kenya and Tanzania in 1998, and the massacre at Nairobi's Westgate Mall four years ago.

Noori and her children arrived 13 months ago in Baidoa, forced to flee because of fighting between al-Shabaab and government forces.

Fatima Ali Hassan used to own dozens of goats and cows. Driven out of her home by drought and demands for money by al-Shabaab, the mother of seven now lives in a tent made out of rags in Baidoa. She's one of tens of thousands who have made their way to this hungry city.

But even here, she's an asset to the terror group, like the other 270,000 displaced people living in the city -- and more are pouring in every day. The UN fears that the ongoing drought will once again threaten Somalia with famine and provide al-Shabaab with even greater opportunities to make money from foreign aid -- particularly if the group maintains control of the main routes through the interior of the country.

Somalia's national army is a patchwork quilt of rival militias sewn together by thin threads of hope that one day it will be able to prevail against the extremists.

Ugandan soldiers prepare for a day of patrol. 22,000 AU troops have been fighting al-Shabaab for years, but are now set to withdraw by 2020.

For now, the country's primary fighting force is a 22,000-strong African Union (AU) contingent that has been protecting the country's fledgling government in Mogadishu, and working to wrest control of south back from al-Shabaab. But it's withdrawing slowly and is expected to be out of the country in two year's time.

The African Union military leadership admits that it can't push al-Shabaab off the major roads that provide it with so much income.

"Instead of reducing [AU forces], it should have been increased," said Lt. Colonel Chris Ogwal. "We are now overstretched, we are just conducting minor offensive operations."

Ogwal commands the Ugandan contingent which controls the road between Mogadishu and the small town of Afgoye -- but not, critically, the rest of the way to Baidoa.

A Somali soldier guards a checkpoint just outside of Afgoye. The route beyond the town remains in the hands of al-Shabaab.

That remains al-Shabaab's financial artery.

Ogwal said that any reduction in AU forces would inevitably leave a vacuum that al-Shabaab would fill.

But this year is the 25th anniversary of the Battle of Mogadishu, the infamous clash in which 18 Americans and more than 1,000 Somalis were killed when US Special Forces attempted to arrest Somalia's most powerful warlord at the time, Mohammed Farrah Aidid.

Images of a dead pilot being dragged through the dust of the Somali capital swiftly undermined a mission that had been intended to bring humanitarian relief and resulted in a US withdrawal two years later.

But the systems of corruption and manipulation of aid in Somalia remained, and have now been co-opted to finance a terrorist movement that controls about a third of the country and may become a magnet for ISIS jihadists on the run from their former caliphate in Syria and Iraq.