mirror of
https://github.com/andrey271192/keenetic-dns-routes.git
synced 2026-09-20 14:42:01 +00:00
aarch64-k3.10 Entware does not have sshpass or cronie packages. Switch to ed25519
SSH key auth and persist via /opt/etc/init.d/S99kdns_tunnel instead of cron.
- /api/routers/{rid}/tunnel-cmd: drop VPS_SSH_PASS dependency, generate one-time
registration token, build install script that:
1. opkg install autossh + openssh-keygen
2. ssh-keygen ed25519 if not exists
3. curl POST pubkey to new register-key endpoint with token
4. autossh -i <key> (no sshpass)
5. /opt/etc/init.d/S99kdns_tunnel for boot autostart
- /api/routers/{rid}/tunnel-register-key: new endpoint, token-auth, appends pubkey
to ~/.ssh/authorized_keys with kdns-tunnel-{rid} comment for de-dup
- copy button: fallback to document.execCommand('copy') for non-HTTPS contexts
(navigator.clipboard requires secure context — UI runs on plain http)
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>