Egypt is working to secure oil supply deals on favourable credit terms from major Arab producers in an attempt to ease fuel shortages and a government cash crunch that have proved politically damaging for the country’s Islamist president, Mohammad Mursi.

Egypt’s neighbour Libya has agreed in principle to offer Cairo close to 1 million barrels a month of crude oil supplies on a lengthy one-year credit term, with the first shipment expected next month, officials from the two countries told The Wall Street Journal.

Another member of the Organisation of the Petroleum Exporting Countries, Iraq, has also agreed on a draft contract to supply Egypt with 4 million barrels of crude a month, said officials from both countries. However, Iraq rebuffed Egypt’s request for a nine-month period of credit and a price discount, and will instead supply the oil at market prices on three-month interest-free credit, the people said.

Egypt has faced a diesel shortage since last year, which has in turn led to rising food costs, long queues at filling stations and electricity blackouts. The fuel crisis has compounded broader economic problems in the country, which in 2011 overthrew the government of Hosni Mubarak in a popular uprising, paving the way for the electoral victory of Mursi’s Muslim Brotherhood party.

Egypt’s government is short of funds and has been negotiating with the International Monetary Fund over a $4.8 billion loan, which analysts and investors say is critical for the country. IMF officials left Cairo earlier this month without agreeing on the terms of the loan.

State-run Egyptian General Petroleum Corp. has been paying hefty premiums for its crude supplies due to the weaker Egyptian pound and is struggling to pay its debt of between $5 billion and $7 billion to foreign energy companies, said one of the oil officials.

The Iraq and Libya deals are “a short-term solution to help Egypt get over the current credit crunch until and if it finalizes terms with the IMF,” said Robin Mills, head of consulting at Manaar Energy in Dubai.

Assuming Egypt can refine the amount of fuel it will secure from Libya and Iraq, it should be enough “to meet most of the fuel shortage during the summer period,” he said.

Libyan oil supplies to Egypt under the new agreement will be worth around $1 billion in total, the officials said. The two countries are still discussing the types of the grade and the quantities of the crude that will be refined in Egypt.

Baghdad plans to supply Cairo with two shipments of Basra light crude each month, starting in May. The deal is worth close to $400 million a month based on current market prices.

Government and industry officials have blamed Egypt’s shortages on lower domestic fuel production, black market trade and an inefficient fuel subsidy system.

Egypt’s oil production fell 3 per cent in January, while its gas production fell to 9 per cent, according to government figures. The country has been facing a slowdown in oil and gas exploration activities over the past couple of years as a result of the continuing civil unrest since the ousting of Mubarak.

Egyptian refineries are running as low as 50 per cent of their capacity, leading to a shortage of state-subsidised diesel that has already severely curtailed road transportation in many parts of the country.

Costly fuel subsidies have been a major contributor to the Egyptian government’s financial woes. By the end of the current fiscal year, the amount allocated for energy subsidies will surge to more than 120 billion Egyptian pounds ($17.33 billion) from the initially budgeted 70 billion pounds due to higher consumption and a sharp fall of the pound, Egyptian oil minister Osama Kamal has repeatedly warned.

The subsidies are delaying aid from the IMF, which is requiring Egypt to make progress on phasing them out before the making the loan.

The fund was on the verge of signing a bailout late last year, but the Egyptian government decided the measures were too controversial at the time. In a country already struggling with civil unrest, any cuts to fuel subsidies could enrage the legions of poor Egyptians who rely daily on cheap fuel, economists say.