Subject: SITE EXEC directories for guest users

From: "Callaway, John" <[email-masked]>
Date: Mon, 29 Mar 1999 11:03:06 -0500

We have a need on our internal FTP server to execute a job after transfers
are done (i.e. our Mainframe programmers cannot figure out how to get us
acceptable files).  I am looking for a non-cron/daemon solution to this for
maintenance reasons.

The issues are as follows:
	Our mainframe computer sends files to a Linux box using ASCII
transfer mode
	The Linux box is connected to the internal network via SMB protocol
	The files need to be stored in DOS format (CR/LF delimited) in order
for our internal users to access the files via applications.

I have tried to get the programmers to create records with CR as the last
character, but they can't get it right.  To get around there inadequacies, I
created a secured script to run 'todos', which works fine for a real users
using SITE EXEC command. 

For security purposes, the mainframe connects using a guest user in order to
keep it from writing in areas where it should not.  The script will not run,
although I can run SITE EXEC (I placed 'ls' in the /bin/ftp-exec directory
to test this.)

If I can't do this using a script or perl, I will write a C program.  I have
also considered a Windows program that users can run to convert the files,
but discarded it.  The current solution is to have them do an FTP transfer
to convert the file.

I would like to keep from writing a 'C' program because our company has
limited 'C' talent and I am moving on to another position.  I am looking for
either a simple UNIX script or Perl solution, if possible.

------------------------------------------------------
John Callaway
Webmaster/UNIX Systems Programmer
Wright Express

http://www.wrightexpress.com