FTP access on HP-UNIX PA RISC

I was facing a typical problem where in the root user can ftp to the unix box, where as other users it denies with the message invalid login. Though we are giving right combination of userid/password. Telnet is working but ftp is not working. Finally resolved it in the following way,

1. /etc/ftpd/ftpusers : this file will have userids that are denied ftp access to the servers.
Ok. The above information is fine. But in our case the above file doesnt exist. So we are not denying any users. So the above info is just info and not related to our problem.
2. ftp calls getusershell which by default checks password information (that is, the entry in /etc/passwd for the user who is trying to log in) against a fixed list. If the shell isn’t on the list, ftp won’t let the user in, so if you use an unusual shell you may not be able to ftp even to your own system
Ok... so what..... well thats not all it does...
getusershell can be made aware of other shells via /etc/shells. Thats it... i checked for /etc/shells and this file doesnt even exist at all. Checked /etc/passwd for the shell we use and found that its /bin/ksh. So created the file /etc/shells with an entry "/bin/ksh" and viola.... ftp works.....

So theres a lot behind the ftp process...........
Credits : http://www.techsolutions.hp.com/en/B2355-90950/ch04s04.html

No comments: