restored ssh key generation code for slave authentication