The gloomy assessment at a conference in America last week came as senior US and Iraqi officials sat down yesterday with officials from Iran, Syria, Jordan and Saudi Arabia in Baghdad to persuade Iraq's neighbours to help seal its borders against fighters, arms and money flowing in. During the conference the US, Iranian and Syrian delegations were reported to have had a 'lively exchange'.

In a bleak analysis, senior officers described the fighters they were facing in Iraq and Afghanistan 'as smart, agile and cunning'.

In Vietnam, the US was eventually defeated by a well-armed, closely directed and highly militarised society that had tanks, armoured vehicles and sources of both military production and outside procurement. What is more devastating now is that the world's only superpower is in danger of being driven back by a few tens of thousands of lightly armed irregulars, who have developed tactics capable of destroying multimillion-dollar vehicles and aircraft.

By contrast, the US military is said to have been slow to respond to the challenges of fighting an insurgency. The senior officers described the insurgents as being able to adapt rapidly to exploit American rules of engagement and turn them against US forces, and quickly disseminate ways of destroying or disabling armoured vehicles.

The military is also hampered in its attempts to break up insurgent groups because of their 'flat' command structure within collaborative networks of small groups, making it difficult to target any hierarchy within the insurgency.

The remarks were made by senior US generals speaking at the Association of the US Army meeting at Fort Lauderdale in Florida and in conversations with The Observer. The generals view the 'war on terror' as the most important test of America's soldiers in 50 years.

'Iraq and Afghanistan are sucking up resources at a faster rate than we planned for,' one three-star general said. 'America's warriors need the latest technology to defeat an enemy who is smart, agile and cunning - things we did not expect of the Soviets.'

Other officers said coalition rules of engagement were being used against the forces fighting the insurgency. 'They know when we can and cannot shoot, and use that against us,' said one officer, reflecting the comments of US soldiers in the field. Another said recent video footage of an ambush on a convoy, posted on the internet, was evidence that insurgents were filming incidents to teach other groups about American counter-measures.

The concerns emerged as Iraq's Prime Minister, Nouri al-Maliki, issued a stern warning that unless Iraq's neighbours - including Iran and Syria - united to help to shut down the networks supplying both Sunni and Shia extremists, Iraq's sectarian bloodshed would engulf the Middle East.

Speaking at the beginning of the conference of regional and international powers in Baghdad, Maliki warned: 'Iraq has become a front-line battlefield. It needs support in this battle, which not only threatens Iraq, but will also spill over to all countries in the region.' Shortly after he spoke, mortar shells landed near the conference site and a car bomb exploded in a Shia stronghold across the city.

Maliki asked for help in stopping financial support, weapons smuggling and 'religious cover' for the relentless car bombings, killings and other attacks that have increasingly been inflicted on Iraq, as the minority Sunnis, who dominated the country under Saddam Hussein, have fought the Shia majority who now run the government.

Terrorism, Maliki said, 'was an international epidemic, the price of which was being paid by the people of Iraq'. He also warned Syria and Iran not to use Iraq as a proxy battlefield against the US: 'Iraq does not accept that its territories and cities become a field where regional and international disputes are settled.'

Maliki said he hoped that today's conference could be a 'turning point in supporting the government in facing this huge danger'. The one-day gathering is also seen as a chance for conversations on its fringe between Iran and the US over the deepening Iranian nuclear crisis - opening the way to end the 28-year diplomatic impasse between America and Iran since the US hostages crisis. The chief US delegate has left open the door for possible one-on-one exchanges about Iraq.