Foreigners and Borders Service
The - SEF () is a police service integrated into the Ministry of Internal Affairs, whose mission is to enforce immigration and asylum in Portugal, in accordance with the provisions of constitutional, legal and governmental guidelines. Among other duties, SEF is the agency responsible for border control and the issuing of residence permits to foreign nationals legally residing in Portugal. Organisation. Headquartered in Lisbon, the SEF is headed by a director general, including central and decentralised services. History. By decree of King Carlos I on August 29, 1893, the Civil Police of Lisbon ("Corpo de Polícia Civil de  Lisboa") were divided into three sections, one of which was the Administrative Inspection Police, which, among other duties, was responsible for the monitoring of foreigners with Portugal. In 1918, the Emigration Police ("Polícia de Emigração") were created through Decree-Law No. 4166 of April 27. The Emigration Police were responsible for the control of the land borders and were a division that worked directly under the General Directorate of Public Safety. In 1928, the Portuguese International Police ("Polícia Internacional Portuguesa") were created with the responsibility of monitoring the land borders and foreigners who resided in Portugal. The International Police operated  under the Information Police ("Polícia de Informações"), a body with responsibility for national security, until it was disbanded in 1931. In 1930 the International Police were moved from the command of the Information Police to the command of the Criminal Investigation Police ("Polícia de Investigação Criminal") as its International Section. Through Decree No. 20 125 of July 28, 1931, the Portuguese International Police returned to the Ministry of the Interior, remaining under direct control of the Ministry. In 1932, the Political and Social Surveillance Section ("Secção de Vigilância Política e Social") of the Portuguese International Police was created, responsible for  preventing and combating crimes of a political and social nature. Through Decree No. 22 151 of January 23, 1933, the Political and Social Surveillance Section was transformed into the Political and Social Defense Police ("Polícia de Defesa Política e Social"), becoming independent of the International Police. By Decree-Law No. 22 992 of August 29, 1933, the Portuguese International Police and the Political and Social Defense Police were once again merged into a single body that became the State Surveillance and Defense Police ("Polícia de Vigilância e Defesa do Estado") (PVDE). The PVDE included an International Section which was responsible  for verifying the entry, stay and exit of foreigners from the National Territory, their detention if they were deemed undesirable, fighting against espionage, and collaboration with the police of other countries. In 1945, through Decree-Law No. 35 046 of October 22, the PVDE was transformed into the International and State Defense Police ("Polícia Internacional e de Defesa do Estado") (PIDE). PIDE was entrusted with administrative functions and functions to prevent and combat crime. As part of its administrative functions, PIDE was responsible for immigration and passport services, land border, sea and air border services and for foreigners' stay and  stay service in Portugal. As part of its functions to prevent and combat crime, it was incumbent upon PIDE to prepare preparatory documents for crimes related to the illegal entry and stay of foreigners in Portugal, border protection against criminal activities crimes of illegal emigration, and crimes against the internal and external security of the State. PIDE was disbanded in 1969, by Decree-Law no. 49 401 of November 24, and the General Directorate for Security ("Direcção-Geral de Segurança") (DGS) was created in its place. The DGS included the Directorate of Foreigners and Border Services ("Direção dos Serviços de  Estrangeiros e Fronteiras"), the basis of the current service which was created in 1974.