Subject: Re: your mail

From: Renato Moutinho Silva <[email-masked]>
Date: Thu, 21 Sep 1995 11:37:58 -0300 (EST)

Dear Subscribers,

	After installing the wu-ftpd on a machine and setting up the account,
the config files and everything else, when trying to make a connection, 
it prompts for a login, but when it comes to prompt for a password, it 
says service not available, or something like that. I saw the log, and it
said my connection was terminated with an exit signal 11 (Segmentation 
Violation). Does anybody around knows what's wrong ??
	I'm using a Sparc Classic SUN station as my ftp server running 
SunOS 4.1.3. The machine isn't the NIS or NFS server and there are NIS 
and NFS servers on the domain. Could it be the problem ?? What should I
do ?? 

					Sincerely Yours, Renato Moutinho

==============================================
Renato Moutinho Silva - Rio de Janeiro, Brasil

Emails: [email-masked]
	[email-masked]
==============================================

---

From: Dave Brower <[email-masked]>
Date: Thu, 21 Sep 95 11:30:37 EDT

>Violation). Does anybody around knows what's wrong ??

I'm having the same error, only on the data connection for a GET. I can
login and ls (over data connection) fine. I got a spark-5 running solaris
however. And is I disable the use of the ftpaccess file (-A rather than -a)
the problem goes away.

I use  anonynous only class 

class   a   anonymous  *

and the following deny line

deny !nameserved /etc/msgs/aftp.no.nameserver

but this should stop the login as I read it, not the data connection.         

I will be trying to trim the ftpaccess of things to see if I can find
one that causes the problem but not until tonight.  Any suggestions
of other things to look at?

thanks,
dcb

--
-------------------------------------------------------------------
Dave Brower                              Internet: [email-masked]
Decision Support Inc.                    voice:    (704) 847-8904
Matthews, NC 28106                       fax:      (704) 847-4875

---

From: Mikko Suonio <[email-masked]>
Date: Fri, 22 Sep 95 10:28:13 EETDST

>and NFS servers on the domain. Could it be the problem ?? What should I

	Hi!

I experienced the same problem with wu-ftpd on Linux. I traced the problem
to the ftphosts file (at least that was the problem in my case). If you
have more than one address restriction on _the first_ line of ftphosts,
it does that SEGV-error. I even got some verifications to this theory in
the following (there are a couple of words in Finnish in it but I guess
you get the idea):

>Article 6236 of sfnet.atk.linux:
>Path: news.helsinki.fi!news.funet.fi!news.cs.hut.fi!katiska.clinet.fi!krisse.www.fi!not-for-mail
>From: [email-masked] (Jaakko Hyvatti)
>Newsgroups: sfnet.atk.linux
>Subject: Re: wu-ftpd slackware 2.3:ssa
>Date: 21 Sep 1995 09:31:16 +0300
>Organization: PiiPää Oy, Helsinki, Finland
>Lines: 68
>Message-ID: <[email-masked]>
>References: <[email-masked]>
>NNTP-Posting-Host: krisse.www.fi
>Mime-Version: 1.0
>Content-Type: text/plain; charset=ISO-8859-1
>Content-Transfer-Encoding: 8bit
>
>Mikko Suonio <[email-masked]> wrote:
>
>421 Service not available, remote server has closed connection .
>
>  wu-ftpd kuoli segmentation violationiin.  Siinä on bugi.  Kokeile
>seuraavaa:
>
>ftp://www.fi/pub/linux/diffs/utils/wu-ftpd-2.4
>
>  Linux C libraries have always been very sensitive to free()ing same
>malloc()ed memory block twice.  This has exposed quite a few bugs
>previously, and now as I installed wu-ftpd-2.4 with linux libc-5.0.0
>this revealed a bug in hostacc.c: endhacc().
>
>  This bug affects all Linux systems that have host access lists with
>multiple hostnames per config line defined.  wu-ftpd crashes with SEGV
>randomly.
>
>  (Seems to me like structure of ha_arr had changed but the deallocator
>routine was left as it is. Am I right?)
>
>  Fix is trivial, patch below:
>
>*** wu-ftpd-2.4/src/hostacc.c.~1~	Mon Aug  1 15:31:38 1994
>--- wu-ftpd-2.4/src/hostacc.c	Thu Apr 13 17:10:05 1995
>***************
>*** 296,308 ****
>          int     iInd;
>          hacc_t  *ptHtmp;
>  
>!         for(iInd=0, ptHtmp = ha_arr;
>!             (ptHtmp->ha_hosts[iInd]);
>!             iInd++)
>!         {
>!                 free(ptHtmp->ha_login);
>!                 free(ptHtmp->ha_hosts[iInd]);
>!         }
>  
>          if (fclose(ptFp))
>                  return (-1);
>--- 296,317 ----
>          int     iInd;
>          hacc_t  *ptHtmp;
>  
>! 	for (ptHtmp = ha_arr;
>! 	     ptHtmp < ha_arr + MAXLIN && ptHtmp->ha_type;
>! 	     ptHtmp++)
>! 	{
>! 		ptHtmp->ha_type = 0;
>! 		if (ptHtmp->ha_login) {
>! 			free(ptHtmp->ha_login);
>! 			ptHtmp->ha_login = NULL;
>! 		}
>! 		for(iInd=0;
>! 		    iInd < MAXHST && ptHtmp->ha_hosts[iInd];
>! 		    iInd++) {
>! 			free(ptHtmp->ha_hosts[iInd]);
>! 			ptHtmp->ha_hosts[iInd] = NULL;
>! 		}
>! 	}
>  
>          if (fclose(ptFp))
>                  return (-1);
>
>  Hope this help someone.
>

  Should I apply this patch? Or are there any better ones? I'm just a little
bit concerned about the security of these things.

--

	Mikko				I $\heartsuit$ _____ !

---

From: Dave Brower <[email-masked]>
Date: Fri, 22 Sep 95 8:49:25 EDT

Morning list,

FYI

After finding nothing (indeed commenting or removing everything) in either
ftpaccess or ftphosts last night, I pulled out a "fix-kit" I'd been using 
and my signal 11 problems went away. This "fix-kit" has a definate linix 
flavor.

-dcb