Subject: RFTP Update/Fix

From: [email-masked]
Date: Tue, 2 Mar 1999 12:28:53 -0500 (EST)

Well, now my problem with RFTP (restricted guest) accounts has become more
interesting.

After trying Beta-18/VR-14, straight Beta-18, and Beta-16, and various
combinations of the new 'restrict uid' rules in the 'ftpaccess' file,
(none of which worked), I decided to try going back to Beta-13.

As soon as I installed the daemon (with no other changes to any of my
guest accounts, config files, etc.), RFTP started working again, and
chrooting users to their designated directories as expected.

Anyone care to speculate why RFTP appears to break in the later versions
of the daemon?

I'm running this all on a stock Sun Ultra Enterprise 1 with stock Solaris
2.5.1...

* In all cases, I got the source, and compiled it using GCC 2.7.2.3. 

* In all cases, the daemon compiles without error messages.

* In all cases, the daemon installs (using build install) without errors.

I've been using wu-ftpd on both Solaris and Linux boxes for a long time
now without ever encountering this kind of difficulty...

Ideas, anyone?

--Duncan

---

From: Gregory A Lundberg <[email-masked]>
Date: Tue, 2 Mar 1999 16:36:54 -0500 (EST)

> (none of which worked), I decided to try going back to Beta-13.

I've pulled CVS diffs between beta-13 and beta-16 (if you want a full set
let me know).

Here's what I see changing over the three revisions.

src/access.c
 - change to when l_compress and l_tar initialized for ftpconversions

src/conversions.c
 - changed parsing scheme for ftpconversions

src/extensions.c
 - correction to handling of ABOR command with out of band data
 - correction of %E magic cookie
 - correction of %M magic cookie
 - correction of %T magic cookie
 - correction of %U magic cookie
 - correction of %u magic cookie
 - garbage collection change for README files
 - additional corrections for out of band data
 - change to path_compare for wildcards
 - change to syntax for upload nodirs option

src/ftpcmd.y
 - correction for PORT command, w/garbage collection, being more critical
   of which ports the client may use on its end and which IP the client
   may send the PORT connection to.  There's a CERT Advisory about this.
 - check for missing parameters on commands
 - Y2K correction, us %04d instead of 19%02d on a response.  This is the
   entire Y2K problem and didn't effect the daemon, but caused problems
   for some clients.
 - garbage collection on errors
 - renamed getline to wu_getline to avoid runtime collision
 - correction to garbage collection for unimplemented commands
 - correction for 213 response for large offset_t machines
 - change some commands to use lreply so '-' on password can suppress

src/ftpcount.c
 - minor changes to match how the daemon really works and show more info

src/ftpd.c
 - grabbed proctitle code from sendmail, replaced old way of showing state
   on ps
 - porting fixes for Unixware and AIX
 - prevent overrun of a few buffers
 - fixes for shadow password support
 - correction for S/Key challenge
 - additional reasons for login failure reported to syslog and removed
   from FTP resonses
 - corrections for S/Key skey_challenge calls
 - renamed logwtmp to wu_logwtmp to prevent runtime collision
 - added support for password expiration
 - moved where the anonymous password warning occurred
 - if user is a guest, they cannot be anonymous
 - anonymous (ftp) doesn't ise /./ hack
 - 550 -> 530 response correction if cannot set uid
 - correction for handling of ftpconversions, stay alive if no file
 - AIX 4.2 porting
 - don't close data socket if it's not open
 - can't do a transfer if no PORT or PASV command was received
 - HP/UX porting
 - fix byte counts reported for transfers
 - fix timeout problems with transfers
 - added testing code for Debian Linux bogosity
 - suppress unneeded newline fot STAT <file>
 - cleanup STAT command output
 - change varargs handling for all reply functions
 - don't check if user can dir rename until after checking dir delete
 - don't allow PASV unless logged in
 - fixup for unique filename generation
 - longjmp in NLST was clobbering some data
 - garbage collection cleanup in NLST

src/ftpshut.c
 - typo

src/glob.c
 - defend against ye olde ../*/.. overrun attack

src/hostacc.c
src/hostacc.h
 - change from static array to malloc'd to remove limits on size

src/logwtmp.c
 - change to wu_logwtmp to avoid runtime conflict

src/pathnames.h
 - support /var/adm area for pid files
 - Solaris 2 lastlog is in /var/adm

src/popen.c
 - get rid of bzero, use memset
 - don't overrun argv array

src/private.c
 - clean up parsing of ftpgroups file

src/realpath.c
 - don't underrun a buffer looking for /

src/config/*
src/makefiles/*
 - many porting changes

support/authuser.c
 - cleanup for Unixware, AIX

support/fnmatch.c
 - replacement of BSD 8.1 with BSD 8.2 version

-- 

Gregory A Lundberg              Senior Partner, VRnet Company
1441 Elmdale Drive              [email-masked]
Kettering, OH 45409-1615 USA    1-800-809-2195