IBM i has support for SSL, for both FTPS (FTP over SSL) and SFTP (FTP over openssh). ftp_ssl_connect uses FTPS, therefor it is necessary that host certificates on OS level are created. You can verify this with CL command "FTP RMTSYS(TEST) SECCNN(*SSL)" with option secure communication st to *SSL. If you can connect to a server where you know that FTPS is possible on server side, it will also work with PHP ftp_ssl_connect.