This article goes over the types of instance ports needed for SFTP Gateway.
The instance ports that are listening should be 22 (SFTP), 2222 (SSH), 80 and 443 (web).
Port 22 is the SFTP port and is needed to be open for SFTP Gateway to work. The port should be open to the world since we restrict SFTP on a per-user basis as one of our features. It is also used to access more user friendly clients such as FileZilla or WinSCP.
Port 2222 is the SSH port and is needed so that you can SSH into the server.
Ports 80 & 443 are the HTTP/HTTPS ports and are used to gain access to the Web Admin UI for SFTP Gateway.
Ports 2222, 80, 443 should be restricted to the sysadmin IP address as shown in the image below.