Summary
kcd connect <ip> dials with targetID = "manual" (internal/daemon/ipc_routes.go), and DialDevice unconditionally copies that into the pre-TLS plaintext identity as TargetDeviceID (internal/daemon/transport.go). The Android app enforces targetDeviceId when present (LanLinkProvider.kt):
val targetDeviceId = identityPacket.getStringOrNull("targetDeviceId")
if (targetDeviceId != null && targetDeviceId != DeviceHelper.getDeviceId(context)) {
Log.e("KDE/LanLinkProvider", "Received a connection request for a device that isn't me: $targetDeviceId")
socket.closeSafe()
return
}
So every manual connect is rejected with isn't me: manual. kcd itself enforces the same rule inbound (transport.go: preBody.TargetDeviceID != "" && != localDeviceID \u2192 drop), so a literal "manual" value is wrong on both sides.
Evidence (live capture, kcd 1.18.1 + KDE Connect Android 1.35.16, Pixel 10a)
Phone logcat at the moment of kcd connect 192.168.178.98:
I KDE/LanLinkProvider: identity packet received from a TCP connection from mercury
E KDE/LanLinkProvider: Received a connection request for a device that isn't me: manual
Daemon side only ever shows the dial (device_id=manual); the phone closes right after reading the identity.
Impact
Combined with no dial-on-startup (auto-reconnect only runs post-drop) and the phone not dialling back on its own, there is currently no working path to (re)establish a link to a known paired device short of a full unpair/re-pair cycle.
Suggested fix
When the target id is unknown (manual connect), omit TargetDeviceID (empty \u2192 field absent) instead of sending the placeholder. The app skips the check when the field is null, and auto-reconnect/pair flows that pass the real id are unaffected.
Summary
kcd connect <ip>dials withtargetID = "manual"(internal/daemon/ipc_routes.go), andDialDeviceunconditionally copies that into the pre-TLS plaintext identity asTargetDeviceID(internal/daemon/transport.go). The Android app enforcestargetDeviceIdwhen present (LanLinkProvider.kt):So every manual connect is rejected with
isn't me: manual. kcd itself enforces the same rule inbound (transport.go:preBody.TargetDeviceID != "" && != localDeviceID\u2192 drop), so a literal "manual" value is wrong on both sides.Evidence (live capture, kcd 1.18.1 + KDE Connect Android 1.35.16, Pixel 10a)
Phone logcat at the moment of
kcd connect 192.168.178.98:Daemon side only ever shows the dial (
device_id=manual); the phone closes right after reading the identity.Impact
Combined with no dial-on-startup (auto-reconnect only runs post-drop) and the phone not dialling back on its own, there is currently no working path to (re)establish a link to a known paired device short of a full unpair/re-pair cycle.
Suggested fix
When the target id is unknown (manual connect), omit
TargetDeviceID(empty \u2192 field absent) instead of sending the placeholder. The app skips the check when the field is null, and auto-reconnect/pair flows that pass the real id are unaffected.