This file is indexed.

/etc/init.d/globus-gridftp-sshftp is in globus-gridftp-server-progs 6.38-1.

This file is owned by root:root, with mode 0o755.

The actual contents of the file can be viewed below.

  1
  2
  3
  4
  5
  6
  7
  8
  9
 10
 11
 12
 13
 14
 15
 16
 17
 18
 19
 20
 21
 22
 23
 24
 25
 26
 27
 28
 29
 30
 31
 32
 33
 34
 35
 36
 37
 38
 39
 40
 41
 42
 43
 44
 45
 46
 47
 48
 49
 50
 51
 52
 53
 54
 55
 56
 57
 58
 59
 60
 61
 62
 63
 64
 65
 66
 67
 68
 69
 70
 71
 72
 73
 74
 75
 76
 77
 78
 79
 80
 81
 82
 83
 84
 85
 86
 87
 88
 89
 90
 91
 92
 93
 94
 95
 96
 97
 98
 99
100
101
102
103
104
105
106
#!/bin/bash
#
# globus-gridftp-sshftp
#
# chkconfig: 2345 20 80
# description: Controls sshftp access to the globus-gridftp-server.
#
### BEGIN INIT INFO
# Provides:          globus-gridftp-sshftp
# Required-Start:    $remote_fs $syslog $network
# Required-Stop:     $remote_fs $syslog
# Default-Start:     2 3 4 5
# Default-Stop:      0 1 6
# Short-Description: Globus GridFTP SSHFTP
# Description:       sshftp access to the Globus Gridftp Server
### END INIT INFO

# source function library
. /lib/lsb/init-functions

sbindir=/usr/sbin
sysconfdir=/etc

rc=0
defaultconf=${sysconfdir}/gridftp-sshftp
enabledconf=/etc/grid-security/sshftp

# Include defaults if available
if [ -r /etc/sysconfig/globus-gridftp-sshftp ] ; then
	. /etc/sysconfig/globus-gridftp-sshftp
fi

start() {
	echo -n "Enabling sshftp access to globus-gridftp-server"

	if [ ! -f $defaultconf ]; then
	  ${sbindir}/globus-gridftp-server-enable-sshftp -out $defaultconf
	  rc=$?
	fi

	if [ $rc -eq 0 -a ! -d /etc/grid-security ] ; then
	  mkdir /etc/grid-security
	  rc=$?
	fi

	if [ $rc -eq 0 -a ! -f $enabledconf ]; then
	  ln -s $defaultconf $enabledconf
	  rc=$?
	fi

	[ $rc -eq 0 ] && log_success_msg || log_failure_msg

	echo
	return $rc
}

stop() {
	echo -n "Disabling sshftp access to globus-gridftp-server"

	if [ -L $enabledconf ]; then
	  rm $enabledconf
	  rc=$?
	elif [ -f $enabledconf ]; then
	  mv $enabledconf ${enabledconf}.save
	  rc=$?
	fi

	[ $rc -eq 0 ] && log_success_msg || log_failure_msg

	echo
	return $rc
}

case "$1" in
    start)
	start
	;;
    stop)
	stop
	;;
    status)
	if [ -f $enabledconf ]; then
	  echo "sshftp access to globus-gridftp-server is enabled."
	  exit 0
	else
	  echo "sshftp access to globus-gridftp-server is disabled."
	  exit 3
	fi
	;;
    restart|force-reload)
	stop
	start
	;;
    reload)
	;;
    reconfigure)
	stop
	${sbindir}/globus-gridftp-server-enable-sshftp -force -out $defaultconf
	start
	;;
    *)
	echo "Usage: $0 {start|stop|status|restart|reload|reconfigure}"
	exit 1
	;;
esac
exit $rc