"These forces [behind the attack] are all basically Chadian forces supported and prepared by Chad and they moved from Chad under the leadership of Khalil Ibrahim," al-Bashir said.
The army said that the curfew was indefinitely extended in Khartoum "to facilitate the capture of those fleeing".
On Saturday, the Chadian government denied "all involvement" in the attack on Khartoum.
"The government denies all involvement in this adventure which it condemns unreservedly, regardless of who was responsible," Mahamat Hissene, a government spokesman, said in a statement.
"The Chadian government, which has always supported efforts for peace in Sudan and in the region, encourages authorities and the opposition [Sudanese rebels] to maintain the voice of dialogue," the statement said.
It was the first time that fighting raging in western Sudan had reached the capital, marking a dramatic widening of the conflict.
The violence in western Sudan has killed thousands and left miliions displaced.
Ibrahim Mahmoud, Sudan's interior minister, said the rebels had been "chased away" three hours after the attack began on Saturday.
Government soldiers paraded seized weapons and captured rebels.
But rebels from the Jem described the attack as a "success".
The Jem website earlier said that its fighters had taken control of Wadi Saidna air force base, just north of Khartoum.
The Sudanese army read out a statement on TV saying: "Army forces are facing attack by rebels loyal to Khalil Ibrahim [Jem leader] in the north of Omdurman."
Omdurman is on the western bank of the Nile opposite Khartoum.
Eltahir Elkaki, general-secretary for the legislative council for Jem, told Al Jazeera by telephone from Libya that "the war will be no longer only in Darfur".
"We haven't changed our tactics," he said. "From the beginning, Jem is a national movement and it has a national agenda.
"We are now in Khartoum and, hopefully, we will be everywhere in the country."
Heavy gunfire and artillery fire could be heard in the streets.
An official from the ruling party said the attack had been defeated and some senior Jem commanders killed. The government has also blamed Chad for backing Jem, a claim Chad denies.
Mandour al-Mahdi, political secretary of the ruling National Congress Party (NCP), said: "The main aim of this failed terrorist sabotage attack was to provoke media coverage and let people imagine that they had the ability to enter Khartoum.
"Thank God this attempt has been completely defeated. Some high-level Jem commanders were killed."
Al-Musalami al-Kabashi, Al Jazeera's Khartoum bureau chief, reported that the clashes were limited to Omdurman and did not reach Khartoum.
The Sudanese interior minister also said that Mohamed Anwar Noor al-Din, the Jem intelligence chief, and Mohamed Saleh, a field commander in Omdurman, had been killed.
According to Mahmoud, the army destroyed more than 40 military vehicles, and seized about 17 others with artillery mortars mounted on them.
'Heavy artillery fire'
Witnesses earlier reported heavy fighting taking place Omdurman.
Sadiq Babo Nimr, a resident, told the AFP news agency by telephone that residents were hiding inside their homes amid heavy artillery fire.
"It's just outside my flat, I can hear bombardment from very heavy artillery," he said.
"We're just lying down, there are stray bullets whistling around the building, my wife and children are very scared."
The UN has condemned the attack. Ban Ki-moon, the UN secretary-general, called for an immediate cessation of the fighting.