Exemplo n.º 1
0
        public static bool mkDir(String remotePath)
        {
            SshConnectionInfo objInfo = new SshConnectionInfo();

            objInfo.User = "******";
            objInfo.Host = "106.75.3.227";
            objInfo.Pass = "******"; //基于密码
            SFTPHelper objSFTPHelper = new SFTPHelper(objInfo);

            return(objSFTPHelper.ftpMkdir(remotePath));
        }
Exemplo n.º 2
0
        public static bool UploadFile(String localPath, String remotePath)
        {
            SshConnectionInfo objInfo = new SshConnectionInfo();

            objInfo.User = "******";
            objInfo.Host = "106.75.3.227";
            objInfo.Pass = "******"; //基于密码
            SFTPHelper objSFTPHelper = new SFTPHelper(objInfo);

            return(objSFTPHelper.Upload(localPath, remotePath));
        }