Bug 355015 - SFTP: Can't browse files on phone using kdeconnect-kde5
Summary: SFTP: Can't browse files on phone using kdeconnect-kde5
Status: RESOLVED FIXED
Alias: None
Product: kdeconnect
Classification: Applications
Component: android-application (show other bugs)
Version: 0.8
Platform: openSUSE Linux
: NOR normal
Target Milestone: ---
Assignee: Albert Vaca Cintora
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2015-11-08 05:14 UTC by Mark
Modified: 2016-10-11 22:43 UTC (History)
11 users (show)

See Also:
Latest Commit:
Version Fixed In:


Attachments
Dolphin (30.47 KB, image/jpeg)
2015-12-13 05:47 UTC, Mark
Details
journalctl log (2.06 KB, text/plain)
2015-12-13 17:22 UTC, Michal Hlavac
Details
description how to access ext sd card content if predefined links are not working (172.89 KB, application/pdf)
2016-02-17 19:22 UTC, alfaflo
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Mark 2015-11-08 05:14:04 UTC
Have installed kdeconnect-kde5  0.8.99 on Leap42.1
I can pair Leap and my nexus5 device without problem and can see the first level of files (All Files, Camera Pictures) can cannot navigate any deeper on my device to other folders.

message given is:
The file or folder /home/farcus/.config/kdeconnect/69a66e057644dd14/kdeconnect_sftp/69a66e057644dd14/storage/emulated/0 does not exist.

a bug which describes the same (or similar problem) is here 
https://bugs.kde.org/show_bug.cgi?id=351725
but this bug has been fixed and I am told that the fix has already been applied to the version of kdeconnect that I am using.

not sure how to debug this . . .  advice on this would help me provide more useful information.

Reproducible: Always
Comment 1 Mark 2015-11-12 02:51:15 UTC
noticed that with android 6.0 (Marshmallow) that connecting with usb, browsing of files cannot be done automatically as it could with previous versions of android. mtp connection must be selected from the notification area on the phone. Default connection via usb is "charging only"
Could my issue perhaps be related to this?
Comment 2 alfaflo 2015-11-16 19:09:30 UTC
I've the same problem
Android 5.1 with latest kdeconnect from google play store ("beta" channel) and kdeconnect-kde5 0.9

If I browse the path manually in dolphin, the sub-folders are empty. So it seems that kdeconnect is not able to "create" and "mount" in my home directory?
Comment 3 Mark 2015-12-13 05:45:19 UTC
this bug is still present for me running kdeconnect-kde5 0.9.0-3.3 with my Nexus 5 running Android 6.0.1
Comment 4 Mark 2015-12-13 05:47:09 UTC
Created attachment 96029 [details]
Dolphin
Comment 5 Michal Hlavac 2015-12-13 17:22:00 UTC
Created attachment 96043 [details]
journalctl log

Attached log from journalctl
Comment 6 ianas 2015-12-15 11:44:53 UTC
I think this is a dolphin issue.
I have the same issue with kdeconnect-kde5 0.9f running openSUSE 42.1
it looks like the kdeconnect:// uri does not work with plasma 5's dolphin.
I tested the old kdeconnect-kde4 0.8 under LEAP and the kdeconnect:// uri works with konqueror (which is still a kde4 app).
I tried it with 2 android 4.4 kitkat devices and while I could send and receive files, control kde, dolphin does not browse android's file system.
Comment 7 Marcelo Vivan Borro 2015-12-15 12:08:38 UTC
Same problem here, kdeconnect-kde5 on Opensuse leap 42.1
Comment 8 Frits Spieker 2015-12-22 13:55:43 UTC
Same problem here. kdeconnect-kde5 on Opensuse Tumbleweed (64 bit)
Comment 9 Johannes Studt 2015-12-28 23:57:56 UTC
+1
Comment 10 Aleix Pol 2015-12-29 02:19:22 UTC
This feature isn't working very well and the original developer didn't really stick around. If nobody can investigate and try to come up with a fix it may have to be removed.

What do you think, Albert?
Comment 11 Johannes Studt 2015-12-29 02:48:37 UTC
It seems that it's only a typo or a changed options behavior:

The kde-connectd logs the following:
kdeconnect.plugin.sftp: Starting process:  "sshfs kdeconnect@192.168.100.156:/ /home/hannes/.config/kdeconnect/84fcee1e9e170ea7/kdeconnect_sftp/84fcee1e9e170ea7 -p 1739 -f -o IdentityFile=/home/hannes/.config/kdeconnect/privateKey.pem -o StrictHostKeyChecking=no -o UserKnownHostsFile=/dev/null -o HostKeyAlgorithms=+ssh-dss"
kdeconnect.plugin.sftp: stdout: "command-line line 0: Bad protocol 2 host key algorithms '+ssh-dss'.\r\nread: Connection reset by peer\n"

When I try to issue this command manually I get the same error:
hannes@gurkenkiste:~> sshfs kdeconnect@192.168.100.156:/ /home/hannes/.config/kdeconnect/84fcee1e9e170ea7/kdeconnect_sftp/84fcee1e9e170ea7 -p 1739 -f -o IdentityFile=/home/hannes/.config/kdeconnect/privateKey.pem -o StrictHostKeyChecking=no -o UserKnownHostsFile=/dev/null -o HostKeyAlgorithms=+ssh-dss
command-line line 0: Bad protocol 2 host key algorithms '+ssh-dss'.
read: Connection reset by peer

Then I tried it without the plus sign like this:
hannes@gurkenkiste:~> sshfs kdeconnect@192.168.100.156:/ /home/hannes/.config/kdeconnect/84fcee1e9e170ea7/kdeconnect_sftp/84fcee1e9e170ea7 -p 1739 -f -o IdentityFile=/home/hannes/.config/kdeconnect/privateKey.pem -o StrictHostKeyChecking=no -o UserKnownHostsFile=/dev/null -o HostKeyAlgorithms=ssh-dss
Warning: Permanently added '[192.168.100.156]:1739' (DSA) to the list of known hosts.

And it worked.
Comment 12 Frits Spieker 2015-12-29 06:55:02 UTC
There is hope! Well spotted Johannes.
Comment 13 Albert Vaca Cintora 2016-01-02 20:45:59 UTC
Git commit 36e62891ca8062344d01c53d7dc5c91cb699690b by Albert Vaca.
Committed on 02/01/2016 at 20:45.
Pushed by albertvaka into branch '0.9'.

This syntax also works on older OpenSSH versions.

Like the one that Ubuntu distributes

M  +1    -1    plugins/sftp/mounter.cpp

http://commits.kde.org/kdeconnect-kde/36e62891ca8062344d01c53d7dc5c91cb699690b
Comment 14 Albert Vaca Cintora 2016-01-02 20:49:10 UTC
I made the fix that Johannes suggested, because it seems to work well in every case. Thanks for your help!
Comment 15 alfaflo 2016-01-04 16:42:54 UTC
(In reply to Albert Vaca from comment #14)
> I made the fix that Johannes suggested, because it seems to work well in
> every case. Thanks for your help!

Thanks Albert,

I've tested the latest git version and now I it works.
Only "path short cuts" for camera and sdcard don't work (show only empty folders; I think paths are wrong), but I can manually access them by editing paths in Dolphin.

Kind regards
Florian
Comment 16 Axel 2016-02-17 17:04:48 UTC
(In reply to alfaflo from comment #15)
> (In reply to Albert Vaca from comment #14)
> > I made the fix that Johannes suggested, because it seems to work well in
> > every case. Thanks for your help!
> 
> Thanks Albert,
> 
> I've tested the latest git version and now I it works.
> Only "path short cuts" for camera and sdcard don't work (show only empty
> folders; I think paths are wrong), but I can manually access them by editing
> paths in Dolphin.
> 
> Kind regards
> Florian

could you say to how correctly edit paths for sdcard and camera?
Comment 17 alfaflo 2016-02-17 19:20:26 UTC
> could you say to how correctly edit paths for sdcard and camera?

Hello Alex

It's little "tricky", so I made a short presentation to show you how I get access to my photos on sd card in my HTC one M8.
Please find it attached.

Kind regards
Florian
Comment 18 alfaflo 2016-02-17 19:22:01 UTC
Created attachment 97269 [details]
description how to access ext sd card content if predefined links are not working
Comment 19 H.H. 2016-10-11 22:43:57 UTC
I have the same problem with ext sdcard, and the workaround with editing the path to a subfolder works. Somebody has a clue, how to fix this bug?