Subject: Re: Options -i, -o and -L are not working

From: Harshal Savalia <[email-masked]>
Date: Fri, 3 Apr 1998 17:05:31 +0500 (IST)

Hello Thomas,

	Its not a problem of syslog level  setting.  Otherwise it should
	not log information when "log commands" directive is specified.

	And what about "-i" and "-o"  options.  It is not  dependent  on
	level of syslog.  Did you check up the code protion which I have
	mentioned in my mail.

	In the file access.c the function acl_setfunctions() initializes
	log_commands,    log_incoming_xfers    and    log_outbound_xfers
	variables  to zero.  I think this is the cause  that  suppresses
	the effect of "-L", "-i" and "-o" command line options.

	Note that if you don't use "-a" option with the above  mentioned
	options then all is ok because  then we are not using  ftpaccess
	file.  So we won't be callig the function acl_setfunctions().

	Did you get my point ? Any way thanks a lot for your response.

Regards,
Harshal

>
>Alright... I've been hanging back because I'm definitely no expert.
>But, when you use the -L option for ftpd to log to syslog, I believe
>there is a little more involved:
>
>I think you have to also tell your logging daemon to look for the
>type of messages ftpd will be sending in order for syslog to accept
>and log them.
>
>There is (at least) /etc/syslog.conf or something similar.
>
>Additionally, mine ( version wu-2.4(4) )is set up with -l
>(lowercase), not -L. Don't know if it matters.
>
>Hope this helps. I'd rather say something than nothing.
>
>tjn
>
>
>> 
>> 
>> Hello,
>> 
>> 	Is it really  true  that  nobody  has  answer to my  (silly  :-)
>> 	question.  I am resending this mail almost for the third time as
>> 	no one  replied me yet.  May be because  the mail is too long to
>> 	read it.  In short my problem  is that  until you  specify  "log
>> 	transfers"  directive in  ftpaccess  file "-i" and "-o"  command
>> 	line  options have no effect.  Similarly  until you specify "log
>> 	commands" directive "-L" command line option have no effect.  If
>> 	you need  more  info.  then go thro'  the mail  attached  below.
>> 
>> 	Please help me if you can!
>> 
>> 	P.S,: I am using wu-ftpd-2.4.2-beta-15 on HP-UX.
>> 
>> Thanks,
>> Harshal
>> 
>> > 
>> > Hello,
>> > 
>> > 	I think there is a problem with the  "-L","-i"  and "-o" options
>> > 	used in the command line options of ftpd.
>> > 
>> > 	I have  started my ftpd daemon with the "-L" option.  I have not
>> > 	included "log commands" directive in my ftpaccess file.  Now man
>> > 	page for ftpd says as follow :
>> > 
>> > 	If the -L option  is  specified,  commands  sent to the  ftpd(8)
>> > 	     server  will be  logged to the  syslog.  The -L  option  is
>> > 	     over-ridden  by the  ftpaccess(5)  file.  If the -L flag is
>> > 	     used, command  logging will be on by default as soon as the
>> > 	     ftp  server is  invoked.  This will cause the server to log
>> > 	     all USER commands,  which if a user  accidentally  enters a
>> > 	     password for that  command  instead of the  username,  will
>> > 	     cause passwords to be logged via syslog.
>> > 
>> > 	So according to man page it should log all USER commands.  But I
>> > 	noticed that until you include "log  commands"  directive in the
>> > 	ftpaccess file it won't log the information.
>> > 
>> > 	In the file access.c the function acl_setfunctions() initializes
>> > 	log_commands  variable  to zero.  I think this is the cause that
>> > 	suppresses the effect of "-L" command line option.
>> > 
>> > 	Similar things  happened when I started ftpd daemon with command
>> > 	line  options  "-i" and "-o".  It is not logging  file  transfer
>> > 	information  in xferlog  file until you include "log  transfers"
>> > 	directive in the ftpaccess file.
>> > 
>> > 	It can happen  that I have  interpreted  the thing  incorrectly.
>> > 	Can any one throw light on this matter.
>> > 
>> > 	Thanks in advance.
>> > 
>> > Regards,
>> > Harshal
>> > 
>> 
>
>

-- 
-------------------------------------------------------------------------------
Harshal Savalia                                 email : [email-masked]
Hewlett Packard - ISO                           Phone : (91)(80)2251554 x 1424
30C, Cunningham Road                            Fax   : (91)(80)2200196
Bangalore 560 052                               Telnet: 847-1424
India.
-------------------------------------------------------------------------------

---

From: Peter Batt <[email-masked]>
Date: Sat, 4 Apr 1998 18:49:13 -0500 (EST)

I recently had problems with these flags.  In my case the pathname to the 
xferlog was not correct for my system BSDI.  Once set, it worked fine to 
log transfers.  However, I still expected to show in other syslog files.  
pb

Peter Batt
LaserNet LLC
703 591 4232

---

From: Harshal Savalia <[email-masked]>
Date: Mon, 6 Apr 1998 14:08:31 +0500 (IST)

Hello Peter,

	It is not a  problem  of  xferlog  pathname.  Because  when "log
	commands"  directive  is present in  ftpaccess  file it logs the
	information  in it.  But if you are using the options "-i", "-o"
	and "-a" and "log  commands"  directive is not  specified in the
	ftpaccess file then it won't log the information.

	I think it is  assumed  in the  implementation  of the ftpd code
	that if you are using the  ftpaccess  file then  "-i",  "-o" and
	"-L"  options  have no more  effect and if user wants to log the
	information  then he has to  specify  propeer  directive  in the
	ftpaccess file.

Regards,
Harshal