REM Set the CYGWIN32 env variable setx CYGWIN32 tty -m REM Set up the mount points regedit /s mounts.reg REM Create the sshd user and assign the necessarry rights net user sshd /del net user sshd password /add net user sshd password ntrights +r SeTcbPrivilege -u sshd ntrights +r SeIncreaseQuotaPrivilege -u sshd ntrights +r SeServiceLogonRight -u sshd ntrights +r SeAssignPrimaryTokenPrivilege -u sshd REM Create the sshusers localgroup net localgroup sshusers /add net localgroup sshusers sshd administrator /add REM Grant sshusers and sshd rights to the appropriate folder structure cacls d:\ /e /g sshusers:r cacls d:\apps /e /g sshusers:r cacls d:\apps\unix /e /g sshd:c sshusers:r /t cacls d:\users /e /g sshdusers:r cacls d:\users\* /e /g sshd:r REM Install the sshd service instsrv sshd remove instsrv sshd d:\apps\unix\usr\local\sbin\srvany.exe regedit /s sshd.reg sc config sshd start= auto obj= %COMPUTERNAME%\sshd password= password REM Clean up the root folder del .\*.* /q