Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Is it works with sftp? #1

Open
kasim1011 opened this issue Mar 12, 2019 · 2 comments
Open

Is it works with sftp? #1

kasim1011 opened this issue Mar 12, 2019 · 2 comments

Comments

@kasim1011
Copy link

Does this FTP client supports sftp protocol

@Paul-DS
Copy link
Owner

Paul-DS commented Mar 12, 2019

Not currently, but you can add it quickly by adding the following line in the file app/src/main/java/com/paulds/simpleftp/data/repository/FtpRepository.java, after the line 109 :

client.setSecurity(FTPClient.SECURITY_FTPS);


If you want to implement it properly in order to manage both FTP and SFTP servers on the same device, you should add a boolean "sftp" in the FtpServer entity (app/src/main/java/com/paulds/simpleftp/data/entities/FtpServer.java), then test if the property is true in the FtpRepository.
You will also have to add a checkbox/switch to enable/disable the SFTP functionality in the server form. See:

  • app/src/main/java/com/paulds/simpleftp/presentation/model/FtpServerViewModel.java
  • app/src/main/java/com/paulds/simpleftp/presentation/activities/EditServerActivity.java
  • app/src/main/res/layout/activity_edit_server.xml

@mustafal
Copy link

Hey @Paul-DS, I had tried to run your repo and I had created a new connection with my Ubuntu PC. The mobile and my PC both are in the same network so can FTP work or not?
and if it will work, how?
can you please explain to me?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants