International Law is the Law of Nations, individuals have no place in it. Over the last 40 years enormous effort has been expended to validate the entirely false concept of Human Rights as individual rights that can be used to appeal beyond the authority of a sovereign democracy's law. This has been done for three connected reasons;
1) Reduce the legal and moral standing of the Democracies to that of the
average arbitrary dictatorship
2) Empower the United Nations and it's administrative legal system
above that of Codes based on consent
3) Gives equal standing to non-state actors in their disputes with
traditional nation states.
The first is shown by the actions of the UN Human Rights Commission, in which dictatorships issue condemnations of democracies. The second is shown by the abuse of the International Court at The Hague and a network of complicit local judges and prosecutors who have assumed the power ex cathedra to launch investigations and threaten to sit in judgement on the conduct of officials of democracies. The third has been used by many criminal and terrorist organizations but the policy was driven and the attendant assaults on the standing of traditional democratic states was formulated for one specific group of non-state actors, the Palestinians.
Does the distinction between citizens and non-citizens mean that a foreigner has no rights? Clearly not but where do those rights that they posses come from?
First is that in International Law a State makes provision for its citizens to be treated with respect and offered due process by the legal system of another country when traveling or doing business. That is done by bilateral treaty between the two Nation-States. It is normal for the relationship agreed upon to be one of mutuality in which each country promises that the citizens of the other will have the same rights that the Sovereign offers to its own.
In theory other arrangements are possible. During the last two centuries treaties were concluded between Western powers and others, notably the Emperor of China and the Caliph of the Ottoman Empire, that granted the citizens of the Western country a higher standing, known as extraterritoriality, than was granted by the asiatic power to its own subjects.
There are nations that do not have treaty arrangements for the protection of each others citizens and commerce. That can be due to a lack of contact, now rare, or hostility short of belligerence such as a failure to recognize a government or a suspended state of hostilities without a Peace Treaty. The United States has no diplomatic relations with the Democratic People's Republic of Korea and if an American were to be incarcerated there we would in theory rely on the United Nations command, really Americans, to intervene or there is often a situation in which another country that does have relations with both will host an "Interests section" within its own embassy that would act to assist if possible. In Cuba there are US diplomats in Havana who are formally part of the Embassy of Switzerland, and there are Cubans in the Swiss Embassy in Washington DC. In some cases no diplomat from the nation whose citizen is effected is present but others acted as a conduit. During the period when the US had no relations with the People's Republic of China we used the good offices of Poland.
When two countries are in a state of war those treaties are broken or put in abeyance and the persons and property of a belligerent will then be subject to seizure. Traditionally with a view towards the restoration of relations after the conclusion of hostilities a nation makes some provision in domestic law to protect alien property during the period of rupture and to intern or deport peaceful civilian noncombatants. More recently the concept of refugees who are citizens of a hostile state but fleeing from it has been introduced. There is also but on a more limited level a set of mutual agreements, like the Geneva Conventions, that set standards for the treatment of subjects of a hostile nation during wartime.
The second set of laws that governs the treatment of aliens within a country is the domestic legal code. For the United States that includes the 14th Amendment injunction that grants all persons "due process" and a realization that our system is rooted in principles that flow from the Judeo-christian tradition.
33 And if a stranger sojourn with thee in your land, ye shall not do him wrong. 34 The stranger that sojourneth with you shall be unto you as the home-born among you, and thou shalt love him as thyself; for ye were strangers in the land of Egypt: I am the LORD your GodFor the US the biblical standard must be codified in the law to be effective but a judge could cite it in determining the intent of a legal or constitutional guide. Each country uses its sources differently or if from a different ethical tradition may use wildly differing sources, and there is no reason to assume that a person traveling overseas will have the same protections that they do in their own country.
My father got his final combat familiarization training from the Nisei. He said they were incredibly tough and good and they told him not to be in a hurry to get up there. One argument I heard about WW-II was that our Germans (Eisenhower etc.) proved better than their Germans. I once had the British Ambassador almost apoplectic in front of me as he was being screened by TSA., "But we are traveling on British Diplomatic Passports!"