Border control refers to measures taken by governments to monitor and regulate the movement of people, animals, and goods across land, air, and maritime borders. While border control is typically associated with international borders, it also encompasses controls imposed on internal borders within a single state. Border control measures serve a variety of purposes, ranging from enforcing customs, sanitary and phytosanitary, or biosecurity regulations to restricting migration. While some borders (including most states' internal borders and international borders within the Schengen Area) are open and completely unguarded, others (including the vast majority of borders between countries as well as some internal borders) are subject to some degree of control and may be crossed legally only at designated checkpoints. Border controls in the 21st century are tightly intertwined with intricate systems of travel documents, visas, and increasingly complex policies that vary between countries. History States and rulers have always regarded the ability to determine who enters or remains in their territories as a key test of their sovereignty, but prior to World War I, border controls were only sporadically implemented. In medieval Europe, for example, the boundaries between rival countries and centres of power were largely symbolic or consisted of amorphous borderlands, 'marches', and 'debatable lands' of indeterminate or contested status and the real 'borders' consisted of the fortified walls that surrounded towns and cities, where the authorities could exclude undesirable or incompatible people at the gates, from vagrants, beggars and the 'wandering poor', to 'masterless women', lepers, Romani, or Jews. The concept of border controls has its origins in antiquity. In Asia, the existence of border controls is evidenced in classical texts. The Arthashastra () makes mention of passes issued at the rate of one masha per pass to enter and exit the country. Chapter 34 of the Second Book of Arthashastra concerns with the duties of the () who must issue sealed passes before a person could enter or leave the countryside. Passports resembling those issued today were an important part of the Chinese bureaucracy as early as the Western Han (202 BCE-220 CE), if not in the Qin Dynasty. They required such details as age, height, and bodily features. These passports (zhuan) determined a person's ability to move throughout imperial counties and through points of control. Even children needed passports, but those of one year or less who were in their mother's care may not have needed them.