home *** CD-ROM | disk | FTP | other *** search
/ Chip 1998 April / ChipCD_498.iso / software / ftp / wftp / winftp.doc < prev    next >
Text File  |  1994-01-07  |  18KB  |  482 lines

  1. WinFTP - A WinSock-based FTP Client for Windows 3.1 and Windows/NT.
  2.  
  3. Written by  :  Santanu Lahiri
  4. Based on    :  WS_FTP & WS_PING by Mr John A. Junod
  5. Release Date:  January 7th, 1993
  6.  
  7. Please read the installation guide before proceeding with the actual
  8. installation of this software, as there are some incompatibilities
  9. with the original version.
  10.  
  11. WinFTP is based on the WS_FTP program originally written by Mr John A. 
  12. Junod, for Microsoft Windows 3.1.  In WinFTP, I have added a few features
  13. that I feel would be nice to have in a program of this kind.  I am using 
  14. the FTP engine from WS_FTP, as I believe Mr. Junod has done a really 
  15. superb job on it,  and I give him full credit for that.  I would like 
  16. to take this opportunity to thank him for releasing the source to Public 
  17. Domain.  That has made it possible for me to learn some of the basics 
  18. of WinSock programming from a working source.
  19.  
  20. I am including the source for the project as part of the release.  
  21. Unfortunately, I do not have the necessary expertise in or access to 
  22. Borland's compiler or environment to make the code portable to either.  
  23. This current version has been compiled with Microsoft Visual C for Windows
  24. and Visual C for Windows NT.  If you adapt this code to Borland's compiler, 
  25. please consider making the source available as Public Domain.  
  26.  
  27. If you run into any bugs in this release, or would like to see other features,
  28. please let me know at the following address, or simply post on alt.winsock.  
  29. I will attempt to maintain the source, but I can not guarantee a prompt 
  30. turn-around.  If you add to or modify the source, please consider contacting 
  31. me so that I can incorporate the changes as well.
  32.  
  33. Internet:     slahiri@magnus.acs.ohio-state.edu
  34. BITNET  :     lahiri@ohsthr
  35.  
  36. Disclaimer.
  37. ------------
  38.  
  39. While I have run this software on several different machines and operating 
  40. systems, and have made an attempt to fix any bugs I've run into, you use 
  41. this software at your own risk.  To the best of my knowledge, the program 
  42. is virus-free and has not exhibited any unusual tendencies to go berserk.  
  43. However, I am not liable for any damages you may incur as a consequence of 
  44. using this software.  
  45.  
  46. Also, while this release was posted using Ohio State University's
  47. resources, OSU is not responsible for it, nor should it be held liable.  My
  48. development of this software was done independent of my connection to
  49. OSU.
  50.  
  51. ------------------------------------------------------------------------
  52.  
  53. Now with the pleasantries out of the way, here is a description of the
  54. release itself.  For those of you who had already gotten the previous
  55. release (WS_FTPB.ZIP, not WS_FTP.ZIP), you will need to make some
  56. modifications to your INI file.  These are detailed later.
  57.  
  58. The INI File Format.
  59. ---------------------
  60.  
  61. The program works on the presumption that it is easier to remember and
  62. understand a descriptive string like "CICA.Indiana Windows File Archive"
  63. rather than the name ftp.cica.indiana.edu.  And the assumption that now
  64. and then we need to log in to the same machine using more than one User
  65. ID.  The concept of a Configuration is that you associate a description
  66. with a combination of Host ID and User ID.  Once a Configuration is
  67. defined, it is unique. 
  68.  
  69. The .INI File format is given below.  You can supply a Configuration
  70. string to name each configuration.  In this version, the HostType 
  71. values are as follows:
  72.  
  73. AutoDetect               0
  74.  
  75. Unix                     1    QVT                      8
  76. IBM VM                   2    IBM/TCP                  9
  77. VMS/Multinet             3    Chameleon               10
  78. VMS/UCX                  4    SuperTCP                11
  79. Ftp Software             5    SI NT FTPD              12
  80. CUTCP/NCSA               6    IBM MVS                 13
  81. NOS                      7    UniSys 5000             14
  82.  
  83. The following file is a sample WINFTP.INI file.  If you wish to set
  84. up a proper initialization file, you must edit all references to
  85. directories and all passwords.
  86.  
  87. WIN16:  Copy the WINFTP.INI file into the WINDOWS directory
  88. WIN32:  Copy the WINFTP.INI file into the \WINNT directory
  89.  
  90. Sample  WINFTP.INI  file:
  91. ---------------------------
  92.  
  93. [WINFTP]
  94. CONFIG=Oakland FTP Service
  95. HOSTNAME=oak.oakland.edu
  96. USERID=anonymous
  97. MAILADDR=slahiri@magnus.acs.ohio-state.edu
  98. VIEWER=d:\pfe\pfe32
  99. LogFile=
  100. LogFlag=On
  101. TempDir=D:\TEMP
  102. ConfigNum=20
  103. ViewerCount=6
  104. Retain=0
  105. DblClk=1
  106. AUTOSTART=1
  107. FLAGS=21
  108. CFG0=Oakland FTP Service
  109. CFG1=Monash FTP Archives
  110. CFG2=Biochemistry
  111. CFG3=Cica FTP Archives
  112. CFG4=SunSite Archives
  113.  
  114. [WINFTP:Viewer]
  115. Viewer1=A,.TXT,D:\PFE\PFE,D:\Docs
  116. Viewer2=I,.ZIP,D:\WIN\WIZ\WIZUNZIP
  117. Viewer3=I,.GIF,D:\WIN\WINGIF\WINGIF,D:\WIN\WINGIF
  118. Viewer4=I,.BMP,D:\WIN\WINGIF\WINGIF,D:\WIN\WINGIF
  119. Viewer5=A,.LST,D:\WIN\GANDER\GANDER
  120. Viewer6=I,.WRI,WRITE
  121.  
  122. [WINFTP:Oakland FTP Service]
  123. HostName=oak.oakland.edu
  124. UserID=anonymous
  125. PASS=slahiri@magnus.acs.ohio-state.edu
  126. HostType=AutoDetect
  127. TimeOut=65
  128. Save=0
  129.  
  130. [WINFTP:Monash FTP Archives]
  131. HostName=ftp.cc.monash.edu.au
  132. UserID=anonymous
  133. PASS=slahiri@magnus.acs.ohio-state.edu
  134. DIR=/pub/win3
  135. HostType=AutoDetect
  136. TimeOut=65
  137. Save=1
  138. DIR1=/pub/win3
  139. DIR2=/pub/win3/access
  140. DIR3=/pub/win3/drivers
  141. DIR4=/pub/win3/drivers/printer
  142. DIR5=/pub/win3/nt
  143.  
  144. [WINFTP:Biochemistry]
  145. HostName=biochemistry.bioc.cwru.edu
  146. UserID=anonymous
  147. PASS=slahiri@magnus.acs.ohio-state.edu
  148. HostType=Unix
  149. TimeOut=65
  150.  
  151. [WINFTP:Cica FTP Archives]
  152. HostName=ftp.cica.indiana.edu
  153. UserID=anonymous
  154. PASS=slahiri@magnus.acs.ohio-state.edu
  155. HostType=AutoDetect
  156. TimeOut=65
  157.  
  158. [WINFTP:SunSite Archives]
  159. HostName=sunsite.unc.edu
  160. UserID=anonymous
  161. PASS=slahiri@magnus.acs.ohio-state.edu
  162. HostType=AutoDetect
  163. TimeOut=65
  164.  
  165.  
  166. Description of Dialogs used in WinFTP
  167. ======================================================
  168.  
  169. The HostName Dialog
  170. ---------------------
  171.  
  172. This dialog appears when you wish to connect to a host and click on the
  173. "Connect" button.  Note that the "Save Configuration" option has now been 
  174. replaced by "Save Directories." and has a different functionality to it.
  175. The components of the dialog are:
  176.  
  177. Config  :  The name assigned to the configuration.  
  178. Host    :  The name of the Remote host you wish to connect to.
  179. UserID  :  User ID you will be logging in with
  180. Passwd  :  Corresponding password
  181. TimeOut :  Time in seconds after which WinFTP will abort the connection.
  182. HostType:  Type of Operating System on the host you are connecting to.
  183.  
  184. Script  :  Name of a Script file.  Not Implemented yet.  DO NOT USE.
  185. Account :  MiniDisk Password option.  Not implemented yet, DO NOT USE.
  186.  
  187. Save Password   :  Will save your password as part of your configuration.
  188. Save Directories:  If selected, will save list of visited directories on
  189.                    Close or Exit.
  190.  
  191. Anonymous Login :  Resets UserID & Passwd fields to appropriate values.
  192. DelCfg  :  Delete Current configuration.
  193. SaveCfg :  Save/Update Current Configuration.
  194. Cancel  :  Cancel the Dialog.
  195. OK      :  Accept Current Configuration & Log in to Host
  196.  
  197. If a configuration name is not supplied, WinFTP will attempt to create
  198. one when saving a configuration.
  199.          
  200. The host types currently supported are listed above in the .INI file 
  201. section.  If the type of host you are logging into is not available 
  202. in the list, please contact me with a directory listing and I will 
  203. attempt to include it.
  204.  
  205.  
  206. The PingHost Dialog
  207. --------------------
  208.  
  209. This dialog allows you to query a name server or your hosts file for the
  210. InterNet address corresponding to a host, and ping that host if you
  211. wish.  The "Resolve" button performs the DNS query, while the "PingHost"
  212. button pings it.  You can specify the size of the Ping packet, and the
  213. repeat count.
  214.  
  215. The Ping code draws heavily on the WS_PING program by John Junod.
  216. Both blocking and async ping operations are supported, at least on the
  217. Trumpet stack.
  218.  
  219. This function is still not quite there, though.  For now, I've only been
  220. able to get it to work with the Trumpet stack, version A17, A18.  It does 
  221. NOT work under Win/NT, or with the FTP Software stack as yet.  It works
  222. with the Trumpet stack only because this stack seems to support the
  223. socket type SOCK_RAW when creating a socket.  Any suggestions as to
  224. using a different socket type or code is welcome.
  225.  
  226.  
  227. The Options Dialog
  228. --------------------
  229.  
  230. Program Options
  231.   Viewer :  Default viewer to use if no association is defined or found.
  232.   EMail  :  Default password for anonymous logins
  233.   TempDir:  Default Directory for temporary files, for viewing purposes.
  234.  
  235.   AutoConnect:  Hostname Dialog to be displayed on startup?
  236.   RetainFiles:  Leave viewed files on Temporary directory to be cleaned
  237.                 up manually.
  238.  
  239. Viewers
  240.   Type   :  File Extension, such as .TXT, .ZIP, .BMP etc to look for.
  241.   Viewer :  Program to use in order to view the selected file.
  242.   VuDir  :  Directory to use for this viewer.
  243.   
  244.   TransferType:  The type to be used (ASCII or Binary) for downloading 
  245.                  files from remote host prior to viewing.
  246.  
  247.  
  248. DoubleClick:  Interpret double-click on a file as a View command or a
  249.               Transfer.
  250.               
  251. FTP Session Options
  252.   Verbose  :  If selected, shows every message being processed.
  253.   Prompt   :  Ask User for file name before transferring files.
  254.   RecvUniq :  Assign Unique File name when receiving files.
  255.   PortCmds :  Internal - Pick Unused port or reuse existing socket.
  256.   Bell     :  Sound bell on transfer
  257.   
  258. Transfer Mode: Default Transfer Mode to use -  ASCII, Binary or L8.
  259.  
  260.  
  261. Viewer Support in WinFTP
  262. ==================================
  263.  
  264. I have added Viewer support for various file types.  You do need to
  265. define the viewers, though.  The section in the .INI file labelled
  266.  
  267.      [WINFTP:Viewer]
  268.  
  269. has the following format:
  270.  
  271. ViewerNN=<TransferType>,<FileExtension>,<ViewerName>[,<ViewerDirectory>]
  272.  
  273. where  TransferType    is A (ASCII) or I (Image/Binary)
  274.        FileExtension   is of the form ".EXT"
  275.        ViewerDirectory is the directory where the file will be viewed
  276.  
  277. Example:
  278.  
  279. Viewer1=A,.TXT,D:\PFE\PFE,D:\Docs       
  280. Viewer2=I,.ZIP,D:\WIN\WIZ\WIZUNZIP
  281.  
  282. If you manually add or delete viewers, you should also update the
  283. ViewerCount variable in the [WINFTP] section
  284.  
  285. The Viewer type is determined by the file extension, so this may or may not 
  286. work for every type of file. Also, when specifying a viewer, you MUST 
  287. specify the transfer type.  For example, if you wish to view .ZIP files, 
  288. you must set the transfer type to Binary, or the downloaded file will be 
  289. garbage.
  290.  
  291. Lastly, if there is no viewer defined, the Windows version will attempt
  292. to use the associations defined for the File Manager.  If it does not
  293. find one, it will use the default viewer, with ASCII transfer type.
  294.  
  295.  
  296.  
  297. Modifying the WS_FTP.INI file from the WS_FTPB release
  298. ======================================================
  299.  
  300. For those of you who downloaded the WS_FTPB.ZIP archive, I apologize for
  301. putting you through this inconvenience.  The WS_FTP.INI filename is now
  302. used by the original WS_FTP program, hence I have changed the name of my
  303. application to WinFTP.  You can convert the WS_FTP.INI file created by
  304. my previous release by renaming the file to WINFTP.INI, and replacing
  305. all occurances of WS_FTP in the file by WINFTP using a text editor like
  306. NotePad, or Edit.
  307.  
  308. I strongly recommend switching over from the WS_FTPB release as there has
  309. been a substantial number of bug fixes in this release of WinFTP.
  310.  
  311. Release Notes :
  312. ==========================================
  313.  
  314.  
  315. December 14th, 1993
  316. --------------------------
  317.  
  318. This release includes a Win16 version of the program as well as a Win32
  319. native application.  The Win32 application was compiled with the Microsoft
  320. Visual C++/NT compiler for a 486 class machine.  I am not sure if it
  321. will also run on a 386.  You are welcome to try it.
  322.  
  323. Following are some of the features of the software:
  324. ----------------------------------------------------
  325.  
  326. +  Configuration Entry as the base unit for the HostName dialog, and
  327.    the ability to save and delete configurations within the dialog. 
  328.    This allows you to have multiple logins defined for the same host
  329.    using different configuration names.
  330.  
  331. +  A "Directory History" box for both local and remote sites so that 
  332.    you can pick a directory you have already visited, without having 
  333.    to traverse the entire directory tree.  
  334.    
  335. +  Association of frequently visited directories with each host.  The
  336.    directories are saved along with the configuration, and the next time
  337.    you log in using the same configuration, the History box is
  338.    initialized with this list.  You do need to set a flag for this.
  339.  
  340. +  File Specification filters.  This will allow you to look for specific 
  341.    file types such as *.txt, or a*.zip in the local and remote hosts.  
  342.    
  343. +  File Viewer support.  You can specify viewers through the Options 
  344.    Dialog and use them to view files at the remote of local host.  If
  345.    no viewer is defined, attempt to use associations from File Manager.
  346.    See the section on Viewer Support for more details.
  347.  
  348. +  Ability to interpret a double-click on a file name as a View command 
  349.    rather than a file transfer.  You can select the mode from the 
  350.    Options dialog.  This was a request from an user of the Norton
  351.    Desktop software.
  352.  
  353. +  Message Logging ability.  Select the Flags/Log To File option on
  354.    the Debug window to enable or disable Message Logging.  by default
  355.    the function is disabled.
  356.    
  357. +  Ability to Ping a remote host.  This is available under the Host menu
  358.    item.  See section on PingHost Dialog for details.
  359.  
  360. Future Enhancements Planned
  361. ----------------------------
  362.  
  363. +  Ability to run scripts.
  364. +  Ability to use MiniDisk Passwords.
  365. +  Ability to perform transfers through firewalls.
  366.  
  367. The software was tested on a 486 PC Clone with several remote hosts 
  368. using Peter Tattam's Trumpet Winsock A17 & A18 with the internal SLIP 
  369. driver.  The Windows NT version was tested using the Microsoft WinSock
  370. implementation released with the Windows NT SDK, final release.
  371.  
  372. The Test Host Types were VMS/Multinet, VMS/UCX, QVT/Net 3.94, Ultrix,
  373. IBM MVS and flavors of Unix as found on various FTP sites.
  374.  
  375.  
  376. Known Bugs:
  377. -------------
  378.  
  379. On the Windows NT version, I get an error when I am uploading a file to
  380. the remote host - "Connection reset by peer".  I am trying to track
  381. this.  However, it does not seem to affect the actual upload. 
  382.  
  383. There is also a resource leak that I have not yet been able to identify.
  384. I believe it may have to do with the way I paint the screen.  But the 
  385. leak is sporadic, and if anyone else notices it, I would like to be 
  386. informed so that I can fix it.  Also any suggestions on tracking it 
  387. is most welcome.
  388.  
  389.  
  390.  
  391. Compiling for Windows Vs Windows NT
  392. ------------------------------------------
  393.  
  394. The source for the program is included in the ZIP file WSFTPSRC.ZIP.  It
  395. is for both environments, except that when compiling under Windows NT,
  396. you need to define the symbol "WIN32".  I have included makefiles for
  397. both Visual C++/Windows and Visual C++/WinNT.  These can serve as a
  398. starting point if you wish to recompile the software.
  399.  
  400.  
  401.  
  402.  
  403. Version of 01/07/94
  404. ==========================================
  405.  
  406. General Notes
  407. -------------------------------------
  408.  
  409. This version should be quite a bit more stable than the last
  410. release.  I have received a number of suggestions as to desired
  411. features.  A few have been implemented, others are still waiting.
  412. For those of you who wanted a macro feature, I am sorry, but
  413. this version is not it.  However, some other ideas are in place
  414. and hopefully will prove useful.
  415.  
  416. Also, this will be the last release with identical code for the 
  417. Windows and Windows NT.  I am reworking the code completely and 
  418. in the next release I would like to take advantage of NT-specific
  419. features such as multithreading and so on.  Don't know how much
  420. time I'll have to devote to that though.  So don't hold your breath.
  421.  
  422.  
  423.  
  424. Bug Fixes:
  425. ------------------------------------------------------------
  426.  
  427. The bug causing WinQVT to choke has been fixed.  Logging out will now 
  428. correctly restore the FTP Server to the Ready state.
  429.  
  430. A memory overwrite that was causing a random GPF has been fixed.
  431.  
  432. A bug that prevented more than twenty configurations has been fixed.
  433.  
  434.  
  435.  
  436. Features added this version:
  437. -----------------------------------
  438.  
  439. +  %Done Bar - This will be displayed on all uploads and on downloads
  440.    where the server sends the file size in bytes to the client. 
  441.  
  442. +  Zoom Window - Lets you view the messages displayed in the main window
  443.    in a separate window, hopefully with a more readable font.
  444.  
  445. +  FireWall Info - You can finally specify the Firewall info from the main
  446.    window.  However, this feature is still untried as I do not have access
  447.    to a firewall host.  Located under the "File" menu item.
  448.  
  449. +  Delete All Dialog - Now you can get around the "Confirm Delete" message
  450.    if you are deleting multiple files.
  451.  
  452. +  DragDrop Capability - Drag a set of files from the File Manager and drop
  453.    them anywhere on the main window to upload them to the remote host.
  454.    
  455. +  Directory Sort feature for Remote Directory.  In this version you can 
  456.    have the remote directory sorted by name or by date & time if you are
  457.    logging in to an Unix Host.  The sorted directory will be visible 
  458.    using the LongDir command.  Unfortunately, I have not implemented it
  459.    for every host type yet, so for non-Unix hosts you can not do this yet.
  460.    Look under the "View" menu item for this option.
  461.    
  462.    
  463. Menu Layout:
  464. ===========================================================================
  465.  
  466. File              View             Hosts          Script     Zoom     About
  467.   WinFTP Setup      Sort By Name     Ping Host
  468.   LogFile Name      Sort By Date     Host Types
  469.   FireWall Setup    DebugWin
  470.   Commands          SaveDir
  471.      CWD, HELP,     Log To File
  472.      LIST,NLST,
  473.      MKD, QUOTE,
  474.      PWD, RETR,
  475.      RMD, STOR
  476.   Connect
  477.   Disconnect
  478.   Download
  479.   Exit
  480.      
  481.      
  482.