UN chief Ban Ki-moon said on Wednesday the United Nations would stand by Libya's side on its path to democracy, on his first visit to Tripoli since the conflict which ousted Moamer Kadhafi.
"The new Libya aspires to be a nation free from fear, free from injustice and free from the oppression of the past," he said after meeting National Transitional Council chief Mustafa Abdel Jalil and other new regime members.
"The United Nations will be your partner in turning those hopes to reality," Ban said during a previously unannounced visit.
He said his talks with Libyan officials covered "public security and the need to secure the arsenals of the previous regime, particularly stocks of shoulder-fired missiles and chemical and biological weapons."
"And we recognised the centrality of human rights and the rule of law," the secretary general said.
"The United Nations stands ready to support the Libyan people in all the areas we discussed -- elections, a new constitution, human rights, public security and the control of weapons," he said.
At a news conference, Ban demanded an immediate end to the Syrian government's crackdown on civilian protesters that has killed more than 3,000 people since mid-March, according to UN figures.
"Killing civilians must stop immediately in Syria," Ban said, calling on Syrian President Bashar al-Assad to implement an Arab peace plan "as soon as possible as agreed."
Signup to our newsletter and follow us on Facebook and Twitter!
"People have suffered to much for too long and it's an unacceptable situation," he said.
Ban during his visit went to a mass grave and met the families of people killed by Kadhafi's forces, UN deputy spokesman Eduardo del Buey said.
"Libyans have paid a heavy price for freedom" and had "inspired the world by throwing off tyranny," he said, while calling for Libya's disparate groups to compromise and stand united.
"As Libya moves forward it will be critical that the people find consensus on major issues and remain united. That in turn will require a great deal of pragmatism, compromise, especially during this very important phase," he said.
The visit had not been previously announced for security reasons. Ban was on his way to the Group of 20 economic powers summit in Cannes, France, where Libya was on the agenda. He was expected in Cannes late on Wednesday.
Ban did not visit Libya during the eight months of the armed uprising which led to the fall of the Libyan regime and the death of Kadhafi on October 20.
His visit comes days after the UN Security Council on Monday called on Libya's interim authorities and neighbouring countries to stamp out the spread of weapons from Kadhafi's huge stockpile.
And NATO ended its UN-mandated mission in the North African nation on October 31.