February 13, 2016 · Quick & Easy
Quick & Easy: Cygwin SSHD and Cron
Quick & Eeasy returns in Windows flavour
SSHD Server
sshd-host-config
- Should StrictModes be used? (yes/no) yes
- Should privilege separation be used? (yes/no) yes
- Enter the value of CYGWIN for the daemon: [] press enter
- Do you want to install sshd as a service? yes
- Do you want to use a different name? (yes/no) no
- Please enter the password for user 'cyg_server: `enter your password
mkpasswd -l -u cyg_server >> /etc/passwdchown cyg_server /var/emptychown SYSTEM /var/emptychmod 600 /var/emptynet start sshd- Now you can login with your username/password with xshell or your favorite ssh client
Crontab
cygrunsrv -I cron -p /usr/sbin/cron -a -Dexport Editor="nano"crontab -enet start cron
tips
net startto start servicenet stopto stop servicesc delete <service>to delete servicecat /var/log/sshd.logto read sshd logcat /var/log/cron.logto read cron log
Todo:
add host keys guide to sshd
Sources (sshd), larsavery, dbaportal
Sources (cron), stockoverflow