Problems using sftp on HMC IBM system

Eduardo Otubo otubo at linux.vnet.ibm.com
Wed Sep 23 04:25:16 EST 2009


William Adams wrote:
>
> It might be useful to examine the account, hcsroot, and the IBM SSH
> configuration.
The hscroot user is a super user, but not necessarily root in the system:

hscroot at hmc:~> cat /etc/passwd |grep hscroot
hscroot:x:500:500:HMC Super User:/home/hscroot:/bin/hmcbash

And the SSH configuration is here:

#       $OpenBSD: sshd_config,v 1.68 2003/12/29 16:39:50 millert Exp $

# This is the sshd server system-wide configuration file.  See
# sshd_config(5) for more information.

# This sshd was compiled with PATH=/usr/bin:/bin:/usr/sbin:/sbin

# The strategy used for options in the default sshd_config shipped with
# OpenSSH is to specify options with their default value where
# possible, but leave them commented.  Uncommented options change a
# default value.

#Port 22
#Protocol 2,1
#ListenAddress 0.0.0.0
#ListenAddress ::

# HostKey for protocol version 1
#HostKey /etc/ssh/ssh_host_key
# HostKeys for protocol version 2
#HostKey /etc/ssh/ssh_host_rsa_key
#HostKey /etc/ssh/ssh_host_dsa_key

# Lifetime and size of ephemeral version 1 server key
#KeyRegenerationInterval 1h
#ServerKeyBits 768
# Logging
#obsoletes QuietMode and FascistLogging
#SyslogFacility AUTH
#LogLevel INFO

# Authentication:

#LoginGraceTime 2m
PermitRootLogin no
#StrictModes yes

#RSAAuthentication yes
#PubkeyAuthentication yes
#AuthorizedKeysFile     .ssh/authorized_keys

# For this to work you will also need host keys in /etc/ssh/ssh_known_hosts
#RhostsRSAAuthentication no
# similar for protocol version 2
#HostbasedAuthentication no
# Change to yes if you don't trust ~/.ssh/known_hosts for
# RhostsRSAAuthentication and HostbasedAuthentication
#IgnoreUserKnownHosts no
# Don't read the user's ~/.rhosts and ~/.shosts files
#IgnoreRhosts yes

# To disable tunneled clear text passwords, change to no here!
PasswordAuthentication yes
#PermitEmptyPasswords no

# Change to no to disable s/key passwords
#ChallengeResponseAuthentication yes

# Kerberos options
#KerberosAuthentication no
#KerberosOrLocalPasswd yes
#KerberosTicketCleanup yes
#KerberosGetAFSToken no

# GSSAPI options
GSSAPIAuthentication yes
GSSAPICleanupCredentials yes

# Set this to 'yes' to enable support for the deprecated 'gssapi' 
authentication
# mechanism to OpenSSH 3.8p1. The newer 'gssapi-with-mic' mechanism is 
included
# in this release. The use of 'gssapi' is deprecated due to the presence of
# potential man-in-the-middle attacks, which 'gssapi-with-mic' is not 
susceptible to.
GSSAPIEnableMITMAttack yes

# Set this to 'yes' to enable PAM authentication (via challenge-response)
# and session processing. Depending on your PAM configuration, this may
# bypass the setting of 'PasswordAuthentication' and 'PermitEmptyPasswords'
UsePAM yes

#AllowTcpForwarding yes
#GatewayPorts no
X11Forwarding yes
#X11DisplayOffset 10
#X11UseLocalhost yes
#PrintMotd yes
#PrintLastLog yes
#TCPKeepAlive yes
#UseLogin no
#UsePrivilegeSeparation yes
PermitUserEnvironment yes
#Compression yes
#ClientAliveInterval 0
#ClientAliveCountMax 3
#UseDNS yes
#PidFile /var/run/sshd.pid
#MaxStartups 10

# no default banner path
#Banner /some/path

# override default of no subsystems
Subsystem       sftp    /usr/lib/ssh/sftp-server
Banner /opt/hsc/data/ssh/ssh_banner
LogLevel ERROR

In the end of the configuration file, there is a Subsystem that points 
to a binary file that I could execute due to restrictions. And that 
Banner file does not exists.

> In particular, if this account is root, is root logon permitted?
> Also, this IBM SSH installation appears to have the SFTP subsystem
> helper enabled.
> How is it configured?
This account is not root, then login is permitted.
The configuration is right up above.
>
> Generally, the IBM SSH daemon and its helpers will place their stdout
> and stderr in /tmp
> or the like. The SSH daemon can be configured to put out some verbose
> error messages
> (just as the client can) which will show you why the connection is being closed.
I just can't reconfigure the SSH daemon due to hscroot permissions, I'll 
talk to the server owner to give me root's password to try those out.

Thanks for the help :)

-- 
Eduardo Otubo
Software Engineer
Linux Technology Center
IBM Systems & Technology Group
Mobile: +55 19 8135 0885 
eotubo at linux.vnet.ibm.com



More information about the openssh-unix-dev mailing list