Lines Matching refs:sshd
45 /usr/sbin/sshd openssh
140 # Remove sshd 22/port from services
141 if [ `/usr/bin/grep -q 'sshd[ \t][ \t]*22' "${_services}"; echo $?` -eq 0 ]
143 /usr/bin/grep -v 'sshd[ \t][ \t]*22' "${_services}" > "${_serv_tmp}"
148 csih_inform "Removing sshd from ${_wservices}"
150 csih_warning "Removing sshd from ${_wservices} failed!"
155 csih_warning "Removing sshd from ${_wservices} failed!"
193 csih_inform "However, this requires a non-privileged account called 'sshd'."
198 if ! csih_create_unprivileged_user sshd
200 csih_error_recoverable "Couldn't create user 'sshd'!"
248 local _sshd_inetd_conf="${_inetcnf_dir}/sshd-inetd"
249 local _sshd_inetd_conf_tmp="${_inetcnf_dir}/sshd-inetd.$$"
260 # check for sshd OR ssh in top-level inetd.conf file, and remove
302 /usr/bin/grep -q '^[ \t]*sshd' "${_inetcnf}" && _with_comment=0
304 # check for sshd in top-level inetd.conf file, and remove
306 if [ `/usr/bin/grep -q '^[# \t]*sshd' "${_inetcnf}"; echo $?` -eq 0 ]
308 /usr/bin/grep -v '^[# \t]*sshd' "${_inetcnf}" >> "${_inetcnf_tmp}"
313 csih_inform "Removed sshd from ${_inetcnf}"
315 csih_warning "Removing sshd from ${_inetcnf} failed!"
320 csih_warning "Removing sshd from ${_inetcnf} failed!"
330 echo 'ssh stream tcp nowait root /usr/sbin/sshd sshd -i' >> "${_inetcnf}"
332 echo '# ssh stream tcp nowait root /usr/sbin/sshd sshd -i' >> "${_inetcnf}"
356 accnt_name=$(/usr/bin/cygrunsrv -VQ sshd | /usr/bin/sed -ne 's/^Account *: *//gp')
369 csih_warning "Couldn't determine name of user running sshd service from /etc/passwd!"
371 csih_warning "by the sshd service belong to the user running the service."
398 if [ -f ${LOCALSTATEDIR}/log/sshd.log ]
400 if ! chown "${run_service_as}".544 ${LOCALSTATEDIR}/log/sshd.log >/dev/null 2>&1
402 csih_warning "Couldn't change owner of ${LOCALSTATEDIR}/log/sshd.log!"
409 csih_warning "This may cause the sshd service to fail! Please make sure that"
418 # Install sshd as a service
426 if /usr/bin/cygrunsrv -Q sshd >/dev/null 2>&1
428 csih_inform "Sshd service is already installed."
431 echo -e "${_csih_QUERY_STR} Do you want to install sshd as a service?"
440 csih_inform "sshd requires. You need to have or to create a privileged"
446 csih_select_privileged_username ${opt_f} ${opt_u} sshd
482 if /usr/bin/cygrunsrv -I sshd -d "CYGWIN sshd" -p /usr/sbin/sshd \
486 csih_inform "The sshd service has been installed under the LocalSystem"
488 csih_inform "\`net start sshd' or \`cygrunsrv -S sshd
492 if /usr/bin/cygrunsrv -I sshd -d "CYGWIN sshd" -p /usr/sbin/sshd \
497 csih_inform "The sshd service has been installed under the '${run_service_as}'"
498 csih_inform "account. To start the service now, call \`net start sshd' or"
499 csih_inform "\`cygrunsrv -S sshd'. Otherwise, it will start automatically"
504 if /usr/bin/cygrunsrv -Q sshd >/dev/null 2>&1
508 csih_error_recoverable "Installing sshd as a service failed!"
607 echo " --port -p <n> sshd listens on port n."
611 echo " instead of LocalSystem for sshd service."
623 # Check for running ssh/sshd processes first. Refuse to do anything while
625 if /usr/bin/ps -ef | /usr/bin/grep -q '/sshd\?$'