What are your rights connected to entering and staying in another country?
Based on the way of entering a country, migration can broadly be divided into regular and irregular migration. Regular migration happens in compliance with the laws of the country, irregular migration means entering or staying in the country without valid authorisation. However, irregular entry does not result in lack of rights.
Migration & Human rights
All migrants are entitled to fundamental rights protected under the general principles of international human rights law. However, states have the right to not provide migrants with rights equal to their citizens (e.g. the right to vote), as well as to limit the rights of irregular migrants compared to migrants lawfully residing in the territory (e.g. the right to work or to receive certain social benefits).
There are also specific rights for different categories of migrants.
example The particular rights of migrant workers are upheld by the UN International Convention on the Protection of the Rights of All Migrant Workers and their Families, which is, however, ratified by a very low number of countries. The specific rights and protections of victims of human trafficking are outlined in the Trafficking Protocol to the UN Convention on Transnational Organized Crime.