(CNN) -- Syrian opposition forces may have executed as many as 30 people, most of them government soldiers, in rural Aleppo, according to the United Nations, which cited videos of the killings posted on the Internet in July.
U.N High Commissioner for Human Rights Navi Pillay called the allegations "deeply shocking" and called Friday for an independent investigation into the incident, which appears to have taken place in Khan al-Assal in northern Syria.
"There needs to be a thorough independent investigation to establish whether war crimes have been committed, and those responsible for such crimes should be brought to justice," Pillay said in a statement.
The videos, posted to the Internet between July 22 and 26, show government soldiers being ordered to lie on the ground, bodies being collected by doctors, corpses strewn along a wall and bodies in Khan al-Assal bearing gunshot wounds to the head.
Pillay's office also has information that Syrian rebels are still holding government officers and soldiers prisoner, the statement said.
Reminding opposition forces that all captured or wounded soldiers must be treated in accordance with international law, Pillay said, "Opposition forces should not think they are immune from prosecution. They must adhere to their responsibilities under international law."
The U.N. Independent International Commission of Inquiry on the Syrian Arab Republic has previously said both rebel groups and government forces and their affiliated militias are demonstrating "emerging patterns of summary execution and murder."
News of the killings came as the Local Coordination Committees, an umbrella group for the opposition, said 19 of its loyalists had been killed, including two children. Most of the deaths came in Damascus, the LCC said.
In a speech to government forces Thursday -- Army Foundation Day -- President Bashar al-Assad said he was confident the government would triumph over the opposition, according to the state-run Syrian Arab News Agency.
''Had we in Syria not been confident of victory, we would not have been able to remain steadfast and resist the aggression for over two years,'' the president said, according to SANA,
The U.N. human rights office also said Friday that investigators have been allowed to visit rebel-controlled Khan al-Assal as part of a separate investigation into the alleged use of chemical weapons.
The rebels announced Friday they had written U.N. Secretary General Ban Ki-moon, requesting an investigation and demanding "that any individuals found to be involved in the deployment of chemical weapons in Syria be held accountable for these crimes."
According to the United Nations, more than 100,000 people have been killed since fighting began. Almost 2 million have fled the country, and 4 million more have been internally displaced.
CNN's Eliott C. McLaughlin contributed to this report.