(CNN) -- Seven members of a joint United Nations-African Union peacekeeping patrol have been killed by a heavily armed militia group in Sudan's Darfur region, the U.N. said.
Peacekeepers drive into a Sudanese refugee camp near Farchana, east of Chad.
Five of those killed were Rwandan, a U.N. peacekeeping official said, and the other two were a Ugandan and a Ghanaian.
Twenty-two others were wounded in the attack, which was immediately condemned by U.N. Secretary-General Ban Ki-moon.
"The attackers used heavy weapons and engaged the UNAMID convoy in an exchange of fire for more than two hours," according to the statement released by Ban's spokesman.
UNAMID is the acronym for the U.N.-AU mission in Darfur. The peacekeepers are allowed to used force when fired upon directly.
"The secretary-general condemns in the strongest possible terms this unacceptable act of extreme violence against AU-U.N. peacekeepers in Darfur and calls on the government of Sudan to do its utmost to ensure that the perpetrators are swiftly identified and brought to justice," the statement said.
"The secretary-general expresses his deepest condolences to the families of the peacekeepers who lost their lives, and reiterates his appreciation for their service, valor and commitment to the search for peace in Darfur."
The ambush happened around 2:45 p.m. (1145 GMT) in northern Darfur. The rescue mission did not take place until after dark, she said.
The peacekeepers who were attacked operated out of Shangil Tobayi -- a base to the west of El Fasher.
In five years of war the U.N. says more than four million people have been affected: Two-and-a-half million people forced from their homes and more than 300,000 killed.
Sudanese officials dispute those numbers claiming only 10,000 have died -- a number they say is normal for five years of war.
U.S. President George W. Bush calls the killings genocide and has put sanctions on Sudan. The U.N. says Sudan's government is guilty of crimes against humanity and of violating international human rights laws every bit as heinous and serious they say as genocide.
In February 2008, a fresh wave of killing forced 58,000 people to flee their homes as government troops and Janjaweed militiamen retaliated against rebels.
A U.N. report said Sudan broke international law as 115 innocent civilians were killed using tactics similar to those employed in 2003, 2004, the worst years of the war.
Peacekeepers are frequently targeted by militias in Darfur, where they are trying to protect civilians from "janjaweed" militias -- nomadic Arab militias, supported by Sudan's government, which target pastoral black Africans.
Ten African Union peacekeepers were killed in October in an ambush on their peacekeeping base -- the deadliest single attack on AU peacekeepers since they began their mission in late 2004.
Don't Miss Rape is a way of life for Darfur's women
Rape is a way of life for Darfur's women Sudan cuts ties with Chad after attack
A U.N. commission concluded in 2005 that the Sudanese government and militias "conducted indiscriminate attacks, including killing of civilians, torture, enforced disappearances, destruction of villages, rape and other forms of sexual violence, pillaging and forced displacement" in Darfur.
In 2006, the U.N. Security Council authorized the creation of the joint AU/U.N. hybrid force of peacekeepers to protect civilians in Darfur. That hybrid force formally took over peacekeeping duties late last year from the force composed solely of members of the African Union.
Yet the force is under-manned as a result of the Sudanese government's opposition to a U.N. presence, with just over 9,500 troops of an authorized strength of 26,000.
All About Darfur • Sudan • UNICEF
At least seven United Nations peacekeepers are dead, and nearly two dozen wounded, after Janjaweed militants in Darfur, Sudan, ambushed their convoy around 11:45 GMT. Five of those troops were from the African nation of Rwanda.

Troops fought with militants for over two hours after militants ambushed their convoy of 40 armoured vehicles. Sudanese media states that ten were wrecked beyond repair.

Hafiz Mohammed, who leads the Sudan program at Justice Africa in London, England, says the latest attack reflects the deteriorating security situation on the ground and that everyone in Sudan is at risk of being attacked.
Kigali International Airport for deployment in Darfur in 2005.
"The situation is very bad. Instead of actually protecting the civilians, they will end up not able even to protect themselves. It's sad to see this happening. It's going to discourage countries to contribute to the unit, which is creating problems. This is the security situation in Darfur, nobody is immune from being attacked," said Mohammed.

The U.N. has condemned the attack releasing a statement saying, "the secretary-general (Ban Ki-moon) condemns in the strongest possible terms this unacceptable act of extreme violence against AU-U.N. peacekeepers in Darfur and calls on the government of Sudan to do its utmost to ensure that the perpetrators are swiftly identified and brought to justice."

The peacekeepers are part of a joint African Union-U.N. mission aimed at putting 26,000 troops in the region. So far only around 10,000 of that planned mission have been ordered to the region. Countries unwilling to contribute forces, and constant government restrictions from Sudan, have contributed to the slow movement of troops to the region.