SSH connection to my WD My Cloud EX2 not as expected

adibs wrote:

 

Since you said that sshd_config is generated on-the-fly, another possibility is to have a startup script somewhere (I’m not sure where exactly yet) that edit that file and amends it to allow additional users (and restart sshd afterwards).

 

You are on the right track for the sshd issue. That startup script is located in /usr/local/modules/script/system_init (btw, that scrpt directory is where all the other shell scripts are kept too, some of which you might want to look at if you were curious about the workings of the EX2). But system_init script is the best starting point to discover a lot. However, the issue you’ll discover is that you cannot still edit the file - because once sshd starts the sshd_config is already written by that program. Moreover, this startup script isread-only…the ONLY way to deal with these twin issues is to figure out how to stop the sshd and then restart sshd and then this change can be put in that startup script only be editing the script and then custom-compiling the firmware with that edited script.

And custom-compiling the firmware is not that difficult.