home *** CD-ROM | disk | FTP | other *** search
/ The Unsorted BBS Collection / thegreatunsorted.tar / thegreatunsorted / hacking / internet / ftpm02.sh / config.pl < prev    next >
Encoding:
Text File  |  1993-05-16  |  7.1 KB  |  217 lines

  1. # Local configuration details for ftpmail.
  2. #
  3. # $Header: /a/swan/home/swan/staff/csg/lmjm/src/perl/mirror/ftpmail/RCS/config.pl,v 1.10 1993/04/25 20:27:48 lmjm Exp lmjm $
  4. # $Log: config.pl,v $
  5. # Revision 1.10  1993/04/25  20:27:48  lmjm
  6. # Added mail_overhead.
  7. #
  8. # Revision 1.9  1993/04/25  14:14:58  lmjm
  9. # Allow for multiple help files (one per language).
  10. #
  11. # Revision 1.8  1993/04/23  23:27:03  lmjm
  12. # Massive renaming for sys5.
  13. #
  14. # Revision 1.7  1993/04/23  17:23:37  lmjm
  15. # Renamed ftpmail-local-config.pl to ftpmail-config.pl
  16. # Made pathnames relative to $ftpmail_dir
  17. #
  18. # Revision 1.6  1993/04/20  20:15:37  lmjm
  19. # Don't attempt to reply to mail from ftpmail!
  20. # Allow for a message of the day file.
  21. #
  22. # Revision 1.5  1993/04/15  14:17:44  lmjm
  23. # Typos fixed.
  24. # Ignore system and admin mail on advice from Christophe
  25. #
  26. # Revision 1.4  1993/04/13  10:34:37  lmjm
  27. # Added more variables to tailor help messages.
  28. # Dont recommend using ftpmail-request
  29. # Changed job pausing.
  30. #
  31. # Revision 1.3  1993/03/30  20:32:21  lmjm
  32. # By default use sendmail.
  33. # By default use immediate.
  34. # Max user settable limit to 100 K.
  35. #
  36. # Revision 1.2  1993/03/23  21:40:13  lmjm
  37. # Now ftpmail_dir is ftpmail's home directory
  38. # Added sendmail, mime and batched processing
  39. #  based on work by Christophe.Wolfhugel@grasp.insa-lyon.fr.
  40. #
  41.  
  42. #-- Needs tailoring ----------------------------------------------------------
  43.  
  44. # Parent directory of the system
  45. # This is now the home direcory of the ftpmail account.
  46. # $ftpmail_dir = "/src.doc.ic.ac.uk/public/ic.doc/ftpmail";
  47.  
  48. # Default site to connect to
  49. $default_site = 'src.doc.ic.ac.uk';
  50.  
  51. # My hostname for Mime multipart message ids and help messages
  52. $hostname = 'src.doc.ic.ac.uk';
  53.  
  54. # ftpmail's full email address in help messages
  55. $ftpmail_email = "ftpmail@$hostname";
  56.  
  57. # Managers email address in help messages
  58. $managers_email = "ukuug-soft@$hostname";
  59.  
  60. # How to send mail - has "-s 'subj'" and the reply-to name appended
  61. # Or use sendmail - this is a much better option.  Also the mime support
  62. # is only available under sendmail.
  63. #  If you give the -f ftpmail-request then all mail will appear to be
  64. # sent by ftpmail-request.  This means that it will require a mailbox or
  65. # alias.  Also beware that a *LOT* of users submit requests to ftpmail by
  66. # replying to older messages to you will have to look out for this.  Using
  67. # -f is therefor NOT recommended.
  68. #$mail_cmd = "/usr/lib/sendmail -t -odi -f ftpmail-request";
  69. $mail_cmd = "/usr/lib/sendmail -t -odi";
  70. # $mail_cmd = "/usr/ucb/mail -v ";
  71.  
  72. # A dumber mailer is one which thinks:
  73. # mail 'Lee McLoughlin <lmjm@doc>' is a message to 3 accounts 'Lee', 'McLoughlin'
  74. # and '<lmjm@doc>.  Most mailers these days are NOT dumb so leave this set to
  75. # 0.
  76. $dumb_mailer = 0;
  77.  
  78. # ftpmail can process jobs in one of two ways
  79. # immediate: after each get/dir/ls mail the result back to the user
  80. # non-immedaite:  keep all the files received by get/dir/ls till the
  81. #            entire jobs is done then mail the results back.  This may
  82. #         use a lot of space.
  83. $immediate = 0;
  84.  
  85. # Cleanup input copies once queued.  If this is set to 0 then
  86. # copies of all input will be left lying around - so cron will have
  87. # to clean it.
  88. $cleanup = 1;
  89.  
  90. # If this file exists exit before the next parse of the queue.
  91. $ftpmail_scan_end = "scan-end";
  92.  
  93. # If set to 1 limit to just login=anonymous, passwd=-ftpmail/$replyto
  94. $restricted = 0;
  95.  
  96. # TODO:
  97. # If set is the name of a file containing restrictions on when to
  98. # attempt to connect to certain sites.  This can be used to allow only
  99. # traffic to the local archive during busy times but allow connections
  100. # everywhere the rest of the time.
  101. #  Each line in the file is either a comment '#.*' or
  102. # day of week: mon|tue|wed|thur|fri|say|sun, an hour range and a site pattern
  103. # eg:  mon|tue|wed|thru|fri 9-18 src.doc.ic.ac.uk
  104. #   only try jobs to the local site during working hours.
  105. $time_restrictions = "restrictions";
  106.  
  107. # TODO:
  108. # Only allow ftp sessions to these sites - default is to all
  109. # it is a regexp matching the sites
  110. # $ftp_permitted = '^.*\.doc\.ic\.ac\.uk$';
  111.  
  112. #-- needs checking -----------------------------------------------------------
  113.  
  114. # Paths for various commands
  115. $btoa = '/usr/local/bin/btoa';
  116. $uuencode = '/usr/local/bin/uuencode';
  117. $compress = '/usr/ucb/compress';
  118.  
  119. # -1 because the higher settings take a lot more time for only 
  120. # a little improvement.
  121. $gzip = '/usr/local/bin/gzip -1';
  122.  
  123. # Mime stuff
  124. $mime_version = '1.0';
  125. $mmencode = '/usr/local/mailcap/mmencode';
  126.  
  127. # Any reply-to name matching this pattern should not be replied to
  128. $dont_reply_to = 'ftpmail|postmaster|mmdf|mailer-daemon|system|admin';
  129.  
  130. #-- may tweek ---------------------------------------------------------------
  131.  
  132. # How long to pause between parses of the queue
  133. $between_runs_pause = 60; # seconds
  134.  
  135. # Max no of commands in a job
  136. $max_cmds = 100;
  137.  
  138. # If a job fails how long to pause before retrying
  139. $retry_pause = 6 * (60 * 60);  # 6 hours
  140.  
  141. # Never try a job more than this many times.
  142. $max_tries = 3;
  143.  
  144. # Pause for this much after each mail sent to avoid flooding the email
  145. # system.  Only set to 0 if using mail does NOT submit in background -
  146. # so sendmail should have mail_pause set to 0.
  147. $mail_pause = 0; # seconds
  148.  
  149. # Files bigger than this are split up - can be reset by 'size num' in job
  150. $def_max_size = 60 * 1024;
  151.  
  152. # Upper limit on what the user can ask for in a size command
  153. $max_size = 100 * 1024;
  154.  
  155. # Asking to split up files smaller than this is ignored
  156. $min_size = 10 * 1024;
  157.  
  158. # This is the size, in bytes, of the extra bits that your mailer adds
  159. # to messages.  It usuall the size of the mail headers (From:..,Date:...)
  160. # Be careful is you have an X.400 mailer as the overheads may be larger.
  161. $mail_overhead = 2048;
  162.  
  163. # Files bigger than this are aborted - to avoid overflowing the
  164. # mail system
  165. $max_processing_size = 10 * 1024 * 1024;
  166.  
  167. # When trying to connect to the ftp daemon
  168. $ftp_port = 21;
  169. $retry_call = 1;    # Do retry
  170. $retry_attempts = 1;    #  but only ONCE
  171.  
  172.  
  173. #-- probably OK ------------------------------------------------------------
  174.  
  175. # All file/directory names are relative to ftpmail_dir
  176.  
  177. # Where temp files are stored (including files being pulled back from
  178. # remote sites).
  179. $tmpdir = "tmp";
  180.  
  181. # Where the ftpmail queue is stored.
  182. $quedir = "queue";
  183.  
  184. # Where copies of the input are kept (you have to remove these manually
  185. # or via a cron job).
  186. $incopydir = "tmp";
  187.  
  188. # Where the authorisation file resides
  189. $authfile = "auth";
  190.  
  191. # Where to keep track of goings on!
  192. $logfile = "log";
  193.  
  194. # Directory containing help files.  helpdir/help is the
  195. # default one returned.  I have this as a symlink to english.
  196. $helpdir = "help";
  197.  
  198. # Message of the day file.  If present then it is emailed back at
  199. # the start of any email response.
  200. $motdfile = "motd";
  201.  
  202. # This file is used to lock processing by dq
  203. # Not releative to $ftpmail_dir.  Keep it in /tmp so it gets wiped automatically
  204. # on a system crash.
  205. $lock = "/tmp/ftpmail.lock";
  206.  
  207. # Used to log an ftp session (this is email back to the user)
  208. $xferlog = "$tmpdir/xferlog";
  209.  
  210. # Temp file where get's and dir's copy into before being emailed
  211. $incoming = "$tmpdir/infile";
  212.  
  213. #-- leave at very end-----------------------------------------------------
  214.  
  215. # Make sure this package returns TRUE
  216. 1;
  217.