Subject: RE: virtual servers with 2.5.0 on Solaris 2.6

From: "Adams, Ann (A.M.)" <[email-masked]>
Date: Tue, 17 Aug 1999 07:55:29 -0400

>   H I
> The virtual servers appear to work 99% .  The issue I appear to
> be having yet is the root directory that NIS users start in.  The
> default appears to be their own /home directory.
> 
> I tried  "virtual <ip addrss> root /home/ftp".  This appears to work for
> anonymous user, but not a standard NIS user.  Is this suppose to work
> for all user? am I missing a configuration user in the ftpaccess user?
> These users can be anywhere in the building and belong to no particular
> group.  The banner line works with the virtual server, so it is reading
> /etc/ftpaccess.
> 
> from the man page...  This makes it appear that this should be
> sufficient.
>   virtual <address> <root|banner|logfile> <path>^M
>    527            Enables  the  virtual  ftp  server  capabilities.
> The^M
>    528            <address>  is the ip address of the virtual server.
> The^M
>    529            second argument specifies that the <path> is either
> the^M
>    530            path  to  the  root  of the filesystem for this
> virtual^M server, the banner presented to the user when  connect-^M
> etc...
> 
> My attempted work arond is to use:
> guestuser *
> guest-root /home/ftp
> in /etc/ftpaccess.  This appears to work and my users now start in
> /home/ftp.  Unfortunately, I have more than one virtual server, so I
> want different servers having different root(home) directories for the
> users.  Is there a way to spcify the virtual server in this case?
> 
> Thanks!

---

From: "Dimitrios Karvounaris" <[email-masked]>
Date: Tue, 17 Aug 1999 14:39:31 +0200

Hi, 

I have setup on a new server BeroFTPD, as I have on my old server. 
But I want to use now chrooted users. 

I have search in the mailinglist archive for infos and have found, that I 
must use guestusers. I have also setup this and if I try this with wu-ftpd 
2.5.0 it is working now without problems. But if I try the same 
configuration with BeroFTPD 1.3.4, it is chrooting only on anonymous 
access, but not with the other users. 
I have tried to compile this with other options and checked twice the 
correct location of ftpaccess, but don't have found the problem. 

Can somebody help me with that? 

Thanx!

# Dimitrios Karvounaris       Email: [email-masked] 
# Bastionstrasse 51           Tel: (02941) 65 80 51
# 59555 Lippstadt             
*
# www.C-IDS.net                 www.WebSitePark.com
*
# Bank:  SSK Lippstadt
# BLZ:   416 500 01
# Konto: 19 513

---

From: Gregory A Lundberg <[email-masked]>
Date: Tue, 17 Aug 1999 09:09:00 -0400

On Tue, Aug 17, 1999 at 07:55:29AM -0400, Adams, Ann (A.M.) wrote:

> > The virtual servers appear to work 99% .  The issue I appear to be
> > having yet is the root directory that NIS users start in.  The default
> > appears to be their own /home directory.
> > 
> > I tried  "virtual <ip addrss> root /home/ftp".  This appears to work
> > for anonymous user, but not a standard NIS user.  Is this suppose to
> > work for all user? am I missing a configuration user in the ftpaccess
> > user?  These users can be anywhere in the building and belong to no
> > particular group.  The banner line works with the virtual server, so it
> > is reading /etc/ftpaccess.
> > 

You could use BeroFTPD to get this.  This is one of the cases where I've
always said BeroFTPD should be used.

Or you could use a fancy inet daemon (xinetd is what I use) and select a
different ftpaccess file for each vhost.  This works but is a pain to set
up.

If you organize your users so the ID numbers are arranged by the vhost you
want the user to use, you can specify those ranges on the guest-root .. ie:

 # No non-anonymous access on the default server
 defaultserver deny * 
 # Except these three
 defaultserver allow user1 user2 user3
 # These users on vhost 1
 virtual vhost1 allow user4 user5 user6
 guest-root /home/vhost1 user4 user5 user6
 # And these on vhost 2
 virtual vhost2 allow user7 user8 user9
 # Users 7 through 9 are UID 20007 through 20009
 guest-root /home/vhost2 %20007-20009

Looking at the code for the defaultserver/virutal allow/deny, I see it ONLY
accepts user NAMES and does not accept UID numbers or ranges.  The code for
guest-root does.  It shouldn't be too much work to copy that code from
guest-root to the allow/deny functions.  [My head's into other things right
now or I'd offer to do it .. if you get it, send the patches along and I'll
propose them for an upcoming release.]

-- 

Gregory A Lundberg              WU-FTPD Development Group
1441 Elmdale Drive              [email-masked]
Kettering, OH 45409-1615 USA    1-800-809-2195

---

From: Gregory A Lundberg <[email-masked]>
Date: Tue, 17 Aug 1999 09:16:34 -0400

On Tue, Aug 17, 1999 at 02:39:31PM +0200, Dimitrios Karvounaris wrote:

> I have setup on a new server BeroFTPD, as I have on my old server.   But
> I want to use now chrooted users. 
> 
> must use guestusers. I have also setup this and if I try this with
> wu-ftpd 2.5.0 it is working now without problems. But if I try the same
> access, but not with the other users.   I have tried to compile this with
> other options and checked twice the correct location of ftpaccess, but
> don't have found the problem. 

I'm sure Bernhard will correct me if I'm wrong ...

If you're talking about the old 'guestgroup' clause, this should be working
in BeroFTPD.  Probably the problem is a missing entry for the users in
/etc/group: there seems to be a lot of confusion by this on both WU-FTPD
and BeroFTPD .. the user MUST be explicitly listed in the named guestgroup
in /etc/groups for guestgroup to take effect.  With BeroFTPD this is
compounded by the possibilty of multiple etc/group files.

If you're talking about guest-root, ISTM this is one of the later features
of WU-FTPD which has not yet made it into BeroFTPD.

--

---

From: "Dimitrios Karvounaris" <[email-masked]>
Date: Sun, 22 Aug 1999 01:25:17 +0200

> > I want to use now chrooted users.=20
> >=20
> > I have search in the mailinglist archive for infos and have found, that
> > I must use guestusers. I have also setup this and if I try this with
> > access, but not with the other users.   I have tried to compile this
> > with other options and checked twice the correct location of ftpaccess,
> > but don't have found the problem.=20
> 
> If you're talking about the old 'guestgroup' clause, this should be
> working in BeroFTPD.  Probably the problem is a missing entry for the
> users in /etc/group: there seems to be a lot of confusion by this on both
> WU-FTPD and BeroFTPD .. the user MUST be explicitly listed in the named
> guestgroup in /etc/groups for guestgroup to take effect.  With BeroFTPD
> this is compounded by the possibilty of multiple etc/group files.
> 

No, that wasn't the problem ... 
I have found now the problem and I am wondering about one thing. 

I have heard, that the hostbased ftpservers like on apache, doesn't 
work, because this isn't official. I has setup before I tried that with the 
chroot a hostbased ftpserver, but forgot this, because I thinked it 
doesn't work. And it has worked, if I was used with only one IP 
different hostnames, that was the reason, that the changes on the 
default ftpaccess-file doesn't applied. I use AbsoluteFTP as ftp-client. 
Has this software implemented the hostbased feature, or why it is 
working on me??? 

# www.C-IDS.net
*
# Bank:  SSK Lippstadt
# BLZ:   416 500 01
# Konto: 19 513