1,285 pts.
 How is my web hosting company’s ftp server setup?
I'm trying to figure out how my web hosting company's ftp server that allows access to my web site is setup. I have ssh access so I can see some of the system files. I'll share some of these system files in order to help figure out how there ftp server is setup.
bash-3.2$ whoami
my_username
-bash-3.2$ pwd  
/etc
-bash-3.2$ cat passwd
root:*:0:0:root:/root:/bin/bash
bin:*:1:1:bin:/bin:/sbin/nologin
daemon:*:2:2:daemon:/sbin:/sbin/nologin
adm:*:3:4:adm:/var/adm:/sbin/nologin
lp:*:4:7:lp:/var/spool/lpd:/sbin/nologin
sync:*:5:0:sync:/sbin:/bin/sync
shutdown:*:6:0:shutdown:/sbin:/sbin/shutdown
halt:*:7:0:halt:/sbin:/sbin/halt
mail:*:8:12:mail:/var/spool/mail:/sbin/nologin
news:*:9:13:news:/etc/news:
uucp:*:10:14:uucp:/var/spool/uucp:/sbin/nologin
operator:*:11:0:operator:/root:/sbin/nologin
games:*:12:100:games:/usr/games:/sbin/nologin
gopher:*:13:30:gopher:/var/gopher:/sbin/nologin
ftp:*:14:50:FTP User:/var/ftp:/sbin/nologin
nobody:*:99:99:Nobody:/:/sbin/nologin
sshd:x:74:74:Privilege-separated SSH:/var/empty/sshd:/sbin/nologin
xfs:x:43:43:X Font Server:/etc/X11/fs:/sbin/nologin
nails:x:500:500:LinuxShield Administration:/home/nails:/bin/sh
mysql:x:100:316:MySQL server:/var/lib/mysql:/bin/bash
gdlinuxmon:*:90001:100450:gdlinuxmon:/home/content:/sbin/nologin
As you see, my username is not listed as one of the system users, but a whoami shows my username.
-bash-3.2$ cd ~
-bash-3.2$ ls -l
total 20
-rw-------  1 ingram87 inetuser  189 May 15 20:42 crontab
drwx---r-x  2 ingram87 inetuser 4096 Feb 17 22:32 data
drwx---r-x 13 ingram87 inetuser 4096 Apr 16 15:17 html
drwx---r-x  2 ingram87 inetuser 4096 Apr 16 15:23 scc
drwx---r-x  3 ingram87 inetuser 4096 Jun  1 18:48 tmp
-bash-3.2$ ls -ln
total 20
-rw-------  1 7474277 100450  189 May 15 20:42 crontab
drwx---r-x  2 7474277 100450 4096 Feb 17 22:32 data
drwx---r-x 13 7474277 100450 4096 Apr 16 15:17 html
drwx---r-x  2 7474277 100450 4096 Apr 16 15:23 scc
drwx---r-x  3 7474277 100450 4096 Jun  1 18:48 tmp
-bash-3.2$
You see my uid number? It's not listed in /etc/passwd either. This leads me to believe that the ftp server uses virtual users. The problem is, all the documentation I've read about ftp virtual users suggest that you have to set the uid of a virtual user to the uid of a system user. Also, I thought when you run "ls -l", it looks up the owner and group from the /etc/passwd file.
My question is: How does this server know my username when I do not have a system account? How can they assign ownership of my home directory to my username when it is not listed in the /etc/passwd file?


Software/Hardware used:
Web server, httpd, ftpd, ftp server
ASKED: June 6, 2011  1:15 AM
UPDATED: October 15, 2011  9:06 PM

Answer Wiki:
Most of the hosting companies use a third party software that hosts the FTP services, users are available in different directory and file. UID is available for built-in FTP unix only, and for other applications.
Last Wiki Answer Submitted:  June 7, 2011  4:11 pm  by  Malzobbi   65 pts.
All Answer Wiki Contributors:  Malzobbi   65 pts.
To see all answers submitted to the Answer Wiki: View Answer History.


Discuss This Question:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _