Chapter 1, Article 1, part 2 states that purpose of the UN Charter is: "To develop friendly relations among nations based on respect for the principle of equal rights and self-determination of peoples, and to take other appropriate measures to strengthen universal peace."
Article 1 in both the International Covenant on Civil and Political Rights (ICCPR) and the International Covenant on Economic, Social and Cultural Rights (ICESCR). Both read: "All peoples have the right of self-determination. By virtue of that right they freely determine their political status and freely pursue their economic, social and cultural development."
The United Nations Universal Declaration of Human Rights article 15 states that everyone has the right to a nationality and that no one should be arbitrarily deprived of a nationality or denied the right to change nationality.
However, the charter and other resolutions did not insist on full independence as the best way of obtaining self-government, nor did they include an enforcement mechanism. Moreover, new states were recognized by the legal doctrine of uti possidetis juris, meaning that old administrative boundaries would become international boundaries upon independence even if they had little relevance to linguistic, ethnic, and cultural boundaries. Nevertheless, justified by the language of self-determination, between 1946 and 1960, the peoples of thirty-seven new nations freed themselves from colonial status in Asia, Africa, and the Middle East. The territoriality issue inevitably would lead to more conflicts and independence movements within many states and challenges to the assumption that territorial integrity is as important as self-determination.
the Item in bold qualifies it all.