DUBAI — With crude oil prices hovering below $50 a barrel in recent months, Saudi Arabia's budget is rapidly shrinking. But despite cuts and financial challenges, a series of ongoing internal and external concerns are driving an increase in the kingdom's defense spending.

The kingdom, which is engaged in an air, ground and naval operation on its southern border with Yemen alongside gulf allies the United Arab Emirates, Qatar and Bahrain, has also been bombing Islamic State extremists in Syria with the US-led international coalition.

Furthermore, analysts state, spending on internal security has sharply increased to stop the threat of terrorism.

"Internal insecurity has also prompted the Saudis to increase military spending as they look to quell their endemic problem with violent extremism," said Matthew Hedges, an independent GCC military analyst.

"The crown prince, Mohammed bin Nayef, has dealt with this issue and is trusted by Saudi Arabia's biggest allies," Hedges said. "He is however jostling for power against King Salman and [Minister of Defense] Mohammed bin Salman. This has enabled problems to flare further, creating an aura aurora of instability in Saudi Arabia."

Monetary analysts expect the slump in oil prices to give the kingdom its biggest deficit in decades.

"The revenue drop is so severe that it's unrealistic to expect spending cuts to have any meaningful impact on the deficit in the near term," Simon Williams, HSBC's chief economist for Central and Eastern Europe, the Middle East and North Africa told Bloomberg. But the longer oil prices stay weak, "the greater the pressure on the authorities," he warned.

The International Monetary Fund predicts Saudi Arabia's budget deficit to exceed 400 billion riyals (US $107 billion) this year, with oil accounting for 81 percent of revenue compared with about 90 percent previously. It expects shortfalls above 10 percent of economic output for the next four years.

"Saudi Arabia can afford its oil regime and the economic status quo in the near term," Bank of America Merrill Lynch economist Jean-Michel Saliba said in a report last month, according to Bloomberg. "However, the domestic macro costs of its unchanged policy choices are likely to become more acute and apparent."

The kingdom is fueling its war and security machine with what appears to be draconian economic measures at home, said Theodore Karasik, a senior adviser for Gulf State Analytics.

"Officials and employees in all sectors are being told to tighten their belts as budgets are reallocated to MoD, (Ministry of Defense), in addition, the kingdom in August started a new campaign to issue a series of government bonds to raise monies that will ultimately go to any defense requirements," he said.

An IHS analysis released in June this year forecasted that the outlook for defense spending in Saudi Arabia remains positive.

"Despite Saudi Arabia's heavy exposure to oil price fluctuations, there have been very few signs of any severe reactionary adjustments to government spending trends," said Craig Caffrey, principal defense budget analyst at IHS Jane's Aerospace, Defence & Security. "The kingdom has only cut defense and security expenditure once over the last 15 years."

The country's defense budget has been expanding at a rate of around 14 percent a year over the last decade and accelerated to a rate of 19 percent a year since 2011. "We certainly expect a significant slowdown in the short term but longer term prospects remain strong," Caffrey said.

IHS Aerospace, Defence & Security forecasts Saudi Arabian defense-specific spending to increase to around $60 billion a year by 2020 from its present $49 billion, making it the fifth-largest spender in the world by that time.

An example of their increased spending is approval of has been a recent request approval to purchase nine UH-60 Black Hawk helicopters worth $495 million.

Karasik said there are likely other measures to be enacted including a lowering of princely allowances.

"There may also be a sell-off of Saudi assets abroad but at the same time, there are reports that Saudi capital flight is starting to occur due to rising panic about the security situation," he added.

Hedges also expects Saudi Arabia to continue curtailing its public spending by liquidating its overseas assets.

"It has been forced to withdraw substantial amounts from its reserves and is in the process of issuing public bonds, mostly in the guise of Sukuk, Sharia-compliant bonds," he said.

"The consistently low price of oil per barrel has placed severe strain on the Saudi economy as it is not well diversified and is crippled by the outlay wastage, particularly in the public sector," he added.

Hedges said that the reign of King Salman, and his son, Mohammed bin Salman, have seen Saudi Arabia take a particularly aggressive foreign policy stance.

"The Saudi-led war in Yemen started nearly two months to the day of the ascension to power by King Salman, an indication of who drove the region to the conflict," he said.

"Saudi Arabia under King Salman has securitized the threat of Iran to an even higher level. The connections between Iran and the Houthis are well-documented but the timing of the war should be seen more in context of the possible lifting of sanctions against Iran. Whilst Iran has and increased its power in the region, mainly through Iraq and Syria, Saudi Arabia has been monumentally affected by low oil prices, a trend that would inevitably continue should sanction against Iran be lifted," he said.

Karasik expects the Al-Saud family to spare no expense in this time of unprecedented challenges to the kingdom from both state and non-state actors.

"Exact current budget estimations are difficult to ascertain because the Saudi press gives certain figures but there is a lot of money circulation that is not taken into account," he said.

Twitter: @Awadz