ewpa / LibSSH-ESP32

Libssh SSH client & server port to ESP32 Arduino library
https://www.ewan.cc/node/157
Other
265 stars 36 forks source link

ESP32 power saving mode while waiting for ssh connection #23

Open defdefred opened 1 year ago

defdefred commented 1 year ago

Thanks a lot for the libssh port, I was able to make this.

Now I wonder if the ESP32 could switch to power saving mode while waiting in ssh_bind_accept(sshbind, session)?

ewpa commented 1 year ago

Good work! Did you get pubkey authentication working? I am not sure what power saving you can achieve if you keep the radio on. For my own projects I use Ethernet with Wake-on-LAN magic packets to achieve something similar.

defdefred commented 1 year ago

Yes, the most difficult part is to understand the way it works without available example. Finally libSSH is automatically doing the signature validation (htps://www.rfc-editor.org/rfc/rfc4252#section-7) while dealing with the client messages so... peace of cake :-).

For power saving, I may try to reduce the cpu freq just before the ssh_bind_accept and to reset to 240Mhz after... https://www.mischianti.org/2021/03/06/esp32-practical-power-saving-manage-wifi-and-cpu-1/