-
Notifications
You must be signed in to change notification settings - Fork 91
SSH: login with keys
roleo edited this page May 31, 2022
·
3 revisions
If you want to login to a ssh session using keys and not password prompt, follow this guide:
- Generate a key on your client device:
ssh-keygen -b 4096
- Login to your camera and create the file /tmp/sd/yi-hack/.ssh/authorized_keys
touch /tmp/sd/yi-hack/.ssh/authorized_keys
-
Copy your key form ~/.ssh/id_rsa.pub to /tmp/sd/yi-hack/.ssh/authorized_keys using vi (copy and paste).
-
Correct the file permissions:
chmod 0600 /tmp/sd/yi-hack/.ssh/authorized_keys
- Restart the cam:
sync
reboot
- If you want to disable the password login, edit /tmp/sd/yi-hack/script/system.sh and add the option "-s" to dropbear.