The SEF agency is ​the Portuguese Immigration and Borders Service. They are a security service within the Ministry of Internal Affairs responsible for documenting foreigners in Portugal, including issuing residence permits, residency renewals, and extending visas to foreign nationals in Portugal.