Pair from separate network or through VPN
Achilleas Koutsou
achilleas.k at gmail.com
Wed Aug 6 13:16:32 UTC 2014
Greetings all,
New guy here.
I've been slowly working on implementing a new feature for KDE connect
that will allow two devices to communicate through separate networks or
through an alternative or non-local network (such as a VPN).
Specifically, I wanted to address Bug 326509 [1] (feature request).
My initial attempt started by adding a new backend for handling
connections through VPNs automatically. There are two problems with this
approach:
- In order to be a general solution, it would have to accommodate all
types of VPNs and VPN interfaces.
- Some VPNs, e.g., OpenVPN in routing mode configured as a tunnel with a
tun interface, don't allow broadcast packets, which is necessary for KDE
Connect to work.
My current approach is to add a new backend and menu for manually
specifying IP addresses of foreign devices. This can also accommodate
hostnames and non-standard port numbers. This was actually Albert Vaca's
original idea which he shared with me when I first contacted him about
working on this issue. Given the nature of KDE Connect, specifically the
fact that it's designed and meant to Just Work, the manual IP input
interface should probably be hidden in an advanced menu.
So far, I've forked the repositories to my GitHub account (both KDE [2]
and Android [3] repositories). On the Android side, I've got a few
things working, mostly hard coded hacks as proof of concept. Specifying
the VPN IP of my desktop in the Android app actually works, but the
pairing is a bit flaky, probably because the KDE side isn't listening on
the VPN interface (?).
In general, when I'm finished with this, it should be possible to pair
and connect two devices that aren't on the same network or when
broadcast isn't possible, as long as the two devices are able to
communicate with one another. This should also work when a device is
behind a NAT/firewall, as long as the specified port is forwarded
appropriately.
This message is intended both as an introduction for myself, to let you
know how I'm thinking about the problem, see if there's anything I
missed about how the connectivity should (or could) work and to ask if
anyone else has any ideas for solving this issue.
So, what do you all think?
Cheers.
--
Achilleas
[1] - https://bugs.kde.org/show_bug.cgi?id=326509
[2] - https://github.com/achilleas-k/kdeconnect-kde
[3] - https://github.com/achilleas-k/kdeconnect-android/tree/manualip
More information about the KDEConnect
mailing list