Can't find the information you are looking for here? Then leave a message over on our WinBatch Tech Support Forum.
WININET WIL Extender DLL Revision History The WinInet dialup/http/https/ftp extender require Windows 98, Windows 2000 or newer. Or an install of MSIE 4.0 will update all required files. The iFtpCmd iGetConStateX functions require MSIE 5.0 or newer Installation: Run the SETUP.WBT file to install the extender for you. Change Info ------------------------------------------------------------------------------------- Version 25014 Aug 4 1998 Initial public release Version 25016 Aug 19 1998 Fixed problem where full path of filename was not returned Fixed problem where the xxxFindNext was missing the first file. Rev 25017 November 24, 1998 DRD Added the constant @FTPPASSIVE to the function iHostConnect. This allows passive ftp transfers. Return error:327 file not found, if user specifies "auto" iFtpDialog (option 2 or 3), and 0 for file size in the function iFtpGet, and the filename specified does not have proper case. Rev 25030 April 7,1999 DRD MAJOR CHANGE: Function parameters modified DLL renamed to wwint33I.DLL (not 32I) iFtpFindInit wasn't properly checking file handles that were NULL. Fixes made to support long file names and file paths. Fixed iDialHangUp, only try to get the details of open connections if there are > 0 open. Fixed a problem where iDial was not returning proper last error information. iFtpOpen needed an additional flag to force a download of the requested file, object, or directory listing from the origin server, not from the cache. Revised iFtpFindInit and iLocFindInit, so we can handle long directory names by setting the 'current working' directories for the user. Added a parameter to iFtpFindinit. 'Match case' which allows the user the specify whether the mask should be case sensitive. Revised iFtpFindNext and iftpLocNext to match a long file name mask. Rev 25031 July 14th, 1999 DRD Fixed 'Access violation' problem in iLocFindNext and iFtpFindNext if subdirectories exceeded 64K. We now reallocate the memory buffer as needed. Added fix for GPF caused by IE 4.0 bug. (if you attempt to set current directory w/ ftpSetCurrentDirectory and FtpFindFirstFile too many times it will crash. Apparently IE 5.0, doesn't have this problem. Rev 25032 July 27, 1999 MHW Modifed iHttpOpen to handle UrlEncoded form data in addition to the multipart form data. Rev 25033 July 29, 1999 DRD Documented iURLEncode and iUrlDecode. Added: function iContentUrl (url-data, keyword, value) Formats a simple variable into encoded URL for a POST-type HTTP request. Rev 25034 Aug 16, 1999 MHW Fixed iHttpOpen did not pass the desired headers in one case. Fixed problem with UrlEncoded Form Data and ihttp POST's. Rev 25035 Aug 29, 1999 MHW Fixed iContentFile added new parameter(file type) and changed how file is read from _lread to FileRead. Rev 25036 Aug 31, 1999 DRD Now returns error 306 bad handle if iOptionSet is given a bad handle. Need to use iOptionSet to set various parameters, immediately after iBegin (the function allocates and defines a top level handle for the other internet functions). Rev 25037 Sept 16, 1999 DRD Added new function iReadDataBuff. Transfers data from an internet host to a binary buffer. Rev 25038 Sept 24, 1999 DRD Fixed problem with iFtpOpen and @Binary Rev 25039 Oct 12, 1999 DRD Fixed problem with iContentURL being called for more than one set of form variables. Rev 25040 Dec 14, 1999 DRD Fixed problem with the iFtpFindNext failing, if an *empty* directory was found in a mulitple directory recursive search. Added new functions (only available with MSIE 5 or newer) iGetConStatEx - retrieves the connected state of the specified internet connection. iFtpCmd - send commands directly to an FTP server. Rev 25041 Jan 11, 2000 Fixed GPF problems with iGetConStatEx and iFtpCmd Documented additional return values for iGetConState and iGetConStatEx Rev 25042 Feb 4, 2000 DRD Fixed problem with iFtpFindNext not "seeing" files with no file root. Rev 25043 Feb 17, 2000 DRD Fixed problem with iClose not sending ftp 'Quit' Command. We attempt to send ftpcommand for Quit if supported (IE5). Apparently problem in Wininet (IE4.0 & 5.0). Rev 25044 March 20, 2000 DRD Fixed problem with iFtpPut and iFtpGet, not attempting to calculate filesize for progess bar, if user specified zero. Rev 25055 Mar 29, 2000 MHW Fixed problem with iDial running under Win2000 Rev 25046 April 20, 2000 MW Added new functions: iPing, iHost2Addr, and iAddr2Host. Rev 25047 May 18, 2000 DRD MW Fixed problem with iClose and certain type of recursive directory searches where the iClose would cause an error. Rev 25048 May 30, 2000 MW DRD Changed iFtpPut, to properly close handle if no file size is given, and to only update dialog, if iDialog is specified. Fixed iFtpPut handling of FTP error 550. Rev 25049 July 21, 2000 MW Fixed iReadDataBuf, which was not returning the entire file in some cases. Rev 25050 Dec 14, 2000 The WinInet extender has been updated to a new format to allow more descriptive function names and additional parameters. This version of the extender requires WinBatch 2001A or newer to run. This extender will not work on WinBatch 2000C or older. In addition, so as not to affect existing scripts using a previous version of this extender, the extender DLL has been renamed to include a 34I in the DLL name instead of a 32I. Old and new versions of this extender can *usually* co-exist side by side. To use the new extender with old scripts and with WinBatch 2001A or newer you will need to change the AddExtender line in the script to reflect the new DLL name. e.g. AddExtender("wwint33i.dll") should become AddExtender("wwint34i.dll") Rev 25051 Jan 17, 2001 DRD Modified iFtpCmd, to accept the following commands: SMNT,TYPE,STRU,MODE,MDTM. Rev 25052 March 29, 2001 DRD Modified iFtpFindNext, and iLocFindNext to handle reallocation of memory for large directory structures. Fixed hanging problem in iFtpFindNext, if directory was access denied while recursing. Rev 25053 April 9, 2001 DRD Fixed a bug, missing slash before filename, in iFtpFindNext, introduced in 25052. Rev 25054 June 22, 2001 DRD Fixed a bug, in iFtpFindInit, returning zero if path with space was given. Rev 25055 Septemeber 27, 2001 DRD Added a new function iWriteDatabuf. Which allows you to copy chunks of a very large file to a FtpServer. (Opposite of iReadDatabuf). Rev 25056 Test build Rev 25057 January 10, 2002 DRD Modified iFtpFindInit, to return zero, if a empty directory is passed and also deallocate memory, if FindFirstFile fails (ie. if an empty directory is passed). Rev 25058 January 11, 2002 DRD Modified iFtpFindInit, to check to see if there are any allocated buffers that need to be freed before allocating new ones . (Fixes a memory leak) Rev 25059 January 12, 2002 DRD Modified iClose, and iLocFindInit to try harder to free memory buffers to plug memory leaks when repeatedly using iFtpFindInit and iLocFindInit funtions. Rev 25060 January 14, 2002 DRD Fixed problem where iGetLastError only ever seems to return an error code of 0 when there is something wrong while calling iDial (i.e. telephone line unplugged). In addition if there is an existing connection iDial did not return the handle to this connection as stated in the documentation, instead returning FALSE (0). Modifications were made to iDial, iDialHangup, and iDialItemize. Fix: iDial, iDialHangup, and iDialItemize will now return error, if unable to locate or load the RasApi32.dll or if not all the necessary functions are available. Rev 25061 April 8, 2002 DRD Modifications were made to iDialItemize, to return error if unable to enumerate ras entries. Made further modifications to iDial and iDialHangup to handle all Windows platforms. iContentUrl, value of a single form variable is nolonger limited to 1K, it has now been bumped up to 8K. Rev 25062 June 20, 2002 DRD Added new functions: iCookieGet,iCookieSet. Rev 25063 Sept 12, 2002 DRD Fixed problem with iDial hanging up right after its connected. Rev 25064 Sept 16, 2002 DRD Fixed problem with iFtpFindInit not handling non-wildcarded file names properly. Rev 25065 Oct 24, 2002 DRD/MW Fixed problem with the default accept type and added a new iHttpAccept function to deal with unusual cases. Rev 20066 Oct 30, 2002 MW Modified progress bar for iFtpDialog to handle files greater than 40MB. Rev 20067 Dec 2, 2002 MW/DRD Fixed(?) a problem with iReadDataBuf returning the error 12031:ERROR_INTERNET_CONNECTION_RESET. Rev 20068 April 2, 2003 DRD Fixed problem with display of FTP dialog. Cancel button is now centered. Rev 20069 April 16, 2003 DRD Added new flags: 'proxy_username' and 'proxy_password' to iOptionSet and iOptionGet. Rev 20070 May 21, 2003 DRD Fixed problem with display of iftpDialog. Status, source and target items are now balanced. Fixed iHostConnect problem where if @HTTPS is specified and the function failed it returned S0 (S-Zero), it now simply returns 0 (zero) Added new function iErrorDialog(handle, error) Displays a dialog box for the error that is passed to InternetErrorDlg, if an appropriate dialog box exists. If the FLAGS_ERROR_UI_FILTER_FOR_ERRORS flag is used, the function also checks the headers for any hidden errors and displays a dialog box if needed. Parameters: (i) Handle - Handle to the Internet connection used in the call to iHttpOpen. (i) Error - Error value for which to display a dialog box. This parameter can be one of the following values. Value Meaning 12039 ERROR_INTERNET_HTTP_TO_HTTPS_ON_REDIR Notifies the user of the zone crossing to and from a secure site. 12014 ERROR_INTERNET_INCORRECT_PASSWORD Displays a dialog box requesting the user's name and password. (On Microsoft® Windows® 95 , the function attempts to use any cached authentication information for the server being accessed before displaying a dialog box.) 12045 ERROR_INTERNET_INVALID_CA Notifies the user that the function does not recognize the certificate authority that generated the certificate for this Secure Sockets Layer (SSL) site. 12043 ERROR_INTERNET_POST_IS_NON_SECURE Displays a warning about posting data to the server through a nonsecure connection. 12038 ERROR_INTERNET_SEC_CERT_CN_INVALID Indicates that the SSL certificate Common Name (host name field) is incorrect. Displays an Invalid SSL Common Name dialog box and lets the user view the incorrect certificate. Also allows the user to select a certificate in response to a server request. 12037 ERROR_INTERNET_SEC_CERT_DATE_INVALID Tells the user that the SSL certificate has expired. 12044 ERROR_INTERNET_CLIENT_AUTH_CERT_NEEDED Displays a dialog box requesting a client certificate. Returns: (i) Returns @TRUE success, @FALSE failure, use iGetLastError() to one of the following values, or any other error value. Return Code Description 1223 ERROR_CANCELLED The function was canceled by the user. 12032 ERROR_INTERNET_FORCE_RETRY This indicates that the function needs to redo ts request. In the case of authentication this indicates that the user clicked the OK button. 6 ERROR_INVALID_HANDLE The handle to the parent window is invalid. Notes: This function checks the headers for any hidden errors and displays a dialog box, if needed. Always inform the user when any of the following events occur: 12039 ERROR_INTERNET_HTTP_TO_HTTPS_ON_REDIR 1204 ERROR_INTERNET_INVALID_CA 12043 ERROR_INTERNET_POST_IS_NON_SECURE 12038 ERROR_INTERNET_SEC_CERT_CN_INVALID 12037 ERROR_INTERNET_SEC_CERT_DATE_INVALID Unless the user has explicitly chosen not to be informed of these events, failure to do so exposes the user involuntarily to a significant security risk. ERROR_INTERNET_CLIENT_AUTH_CERT_NEEDED Notes: If error 12044 ERROR_INTERNET_CLIENT_AUTH_CERT_NEEDED is specified, iErrorDialog must be called after iHttpOpen fails with the error ERROR_INTERNET_CLIENT_AUTH_CERT_NEEDED (12044). iErrorDialog always returns ERROR_SUCCESS for ERROR_INTERNET_CLIENT_AUTH_CERT_NEEDED regardless of whether you click OK or Cancel. Because iErrorDialog always returns ERROR_SUCCESS, it may be tricky to determine if the user clicked Cancel. If Cancel is clicked, then a certificate is not sent. If OK is clicked, the certificate is sent. If the client certificate is not sent but the server requires it, the server will return the 403 HTTP status code. You can query the status code by using the function iHttpHeaders, or checking the return value of the iHttpOpen. if Cancel is clicked, you will receive error 403 on the second retry of iHttpOpen after iErrorDialog was called. Added new function iParseUrl( url, flag, request) Breaks a URL into its component parts. Parameters (s) Url the canonical URL to be cracked. (i) Flags controls the operation. This parameter can be one of the following values. Value Meaning 0 No flags (default) 268435456 ICU_DECODE - Converts encoded characters back to their normal form. This can be used only if the user provides buffers in the URL_COMPONENTS structure to copy the components into. 2147483648 ICU_ESCAPE - Converts all escape sequences (%xx) to their corresponding characters. This can be used only if the user provides buffers in the URL_COMPONENTS structure to copy the components into. (i) Request specifies which URL component is retrieved. 0 - Scheme name (for example, http, https, ftp, file) 1 - HostName (for example, techsupt.winbatch.com) 2 - UserName 3 - Password 4 - UrlPath (for example, /somewhere/something.htm or /somewhere/something.cgi). 5 - ExtraInfo (for example, ?something or #something). Return (i/s) specified request string, or 0 upon failure, to get extended error information, call iGetLastError. Note: Do not use iParseUrl on file:// URLs that contain spaces, because the value returned is too large. This is only the case, however, with file:// URLs that contain space characters. Rev 25071 May 30, 2003 DRD Added new option "client_cert_context" to iOptionSet. If an application receives ERROR_INTERNET_CLIENT_AUTH_CERT_NEEDED, use this option to supply a certificate before retrying the request. Added new function iGetIEVer() Returns Internet Explorer's version string. Parameters: none Returns: (s) version resource string Note: this function requires Internet Explorer 4.0 or later. Internet Explorer version numbers for Windows 95, Windows 98, Windows 98 Second Edition, Windows Millennium Edition (Me), Windows NT 4.0, Windows 2000, Windows XP, and Windows Server 2003 use the following format: {major version}.{minor version}.{build number}.{sub-build number} This table includes possible Internet Explorer version numbers. Version Product ----------------------------------------------------------------- 4.40.308 Internet Explorer 1.0 (Plus! for Windows 95) 4.40.520 Internet Explorer 2.0 4.70.1155 Internet Explorer 3.0 4.70.1158 Internet Explorer 3.0 (Windows 95 OSR2) 4.70.1215 Internet Explorer 3.01 4.70.1300 Internet Explorer 3.02 and 3.02a 4.71.544 Internet Explorer 4.0 Platform Preview 1.0 (PP1) 4.71.1008.3 Internet Explorer 4.0 Platform Preview 2.0 (PP2) 4.71.1712.6 Internet Explorer 4.0 4.72.2106.8 Internet Explorer 4.01 4.72.3110.8 Internet Explorer 4.01 Service Pack 1 (Windows 98) 4.72.3612.1713 Internet Explorer 4.01 Service Pack 2 5.00.0518.10 Internet Explorer 5 Developer Preview (Beta 1) 5.00.0910.1309 Internet Explorer 5 Beta (Beta 2) 5.00.2014.0216 Internet Explorer 5 5.00.2314.1003 Internet Explorer 5 (Office 2000) 5.00.2614.3500 Internet Explorer 5 (Windows 98 Second Edition) 5.00.2516.1900 Internet Explorer 5.01 (Windows 2000 Beta 3, build 5.00.2031) 5.00.2919.800 Internet Explorer 5.01 (Windows 2000 RC1, build 5.00.2072) 5.00.2919.3800 Internet Explorer 5.01 (Windows 2000 RC2, build 5.00.2128) 5.00.2919.6307 Internet Explorer 5.01 (Office 2000 SR-1) 5.00.2920.0000 Internet Explorer 5.01 (Windows 2000, build 5.00.2195) 5.00.3103.1000 Internet Explorer 5.01 SP1 (Windows 2000 SP1) 5.00.3105.0106 Internet Explorer 5.01 SP1 (Windows 95/98 and Windows NT 4.0) 5.00.3314.2101 Internet Explorer 5.01 SP2 (Windows 95/98 and Windows NT 4.0) 5.00.3315.1000 Internet Explorer 5.01 SP2 (Windows 2000 SP2) 5.00.3502.1000 Internet Explorer 5.01 SP3 (Windows 2000 SP3 only) 5.50.3825.1300 Internet Explorer 5.5 Developer Preview (Beta) 5.50.4030.2400 Internet Explorer 5.5 & Internet Tools Beta 5.50.4134.0100 Internet Explorer 5.5 for Windows Me (4.90.3000) 5.50.4134.0600 Internet Explorer 5.5 5.50.4308.2900 Internet Explorer 5.5 Advanced Security Privacy Beta 5.50.4522.1800 Internet Explorer 5.5 Service Pack 1 5.50.4807.2300 Internet Explorer 5.5 Service Pack 2 6.00.2462.0000 Internet Explorer 6 Public Preview (Beta) 6.00.2479.0006 Internet Explorer 6 Public Preview (Beta) Refresh 6.00.2600.0000 Internet Explorer 6 (Windows XP) 6.00.2800.1106 Internet Explorer 6 Service Pack 1 (Windows XP SP1) 6.00.3663.0000 Internet Explorer 6 for Microsoft Windows Server 2003 RC1 6.00.3718.0000 Internet Explorer 6 for Windows Server 2003 RC2 6.00.3790.0000 Internet Explorer 6 for Windows Server 2003 (released) Rev 25072 July 8, 2003 DRD Modified iFtpFindNext to return file attributes if extended info is @true. Removed all moderate level errors. Rev 25073 July 30th, 2003 DRD Modified iLocFindInit to handle relative file paths. iFtpFindNext nolonger changes the current working directory of the script. Also fixed problem with iFtpFindNext returning file paths with forward slashes. Rev 25074 Sept 26th, 2003 DRD Modified progress bar for iFtpDialog to handle files greater than 40MB. (2G limit) Fixed 'percentage text' overlapping the progress bar in the iFtpDialog dialog. Rev 44075 April 11th, 2005 DRD Added optional parameter to iFtpGet and iFtpPut to keep alive the connection. Removed 32k total string length limitation and removed 8k value limitation from iContentUrl. The WinInet extender has been updated to a new format to allow more descriptive function names and additional parameters. This version of the extender requires WinBatch 2004B or newer to run. This extender will not work on WinBatch 2004A or older. In addition, so as not to affect existing scripts using a previous version of this extender, the extender DLL has been renamed to include a 44I in the DLL name instead of a 34I. Old and new versions of this extender can *usually* co-exist side by side. To use the new extender with old scripts and with WinBatch 2004B or newer you will need to change the AddExtender line in the script to reflect the new DLL name. e.g. AddExtender("wwint34i.dll") should become AddExtender("wwint44i.dll") Rev 44076 June 30th 2005 DRD Removed handling of FTP error 550 in iFtpGet and iFtpPut. This should fix problem where iFtpGet successfully retrieved the file but incorrectly returned 0 if the servers response contained the 550 error. Rev 44077 July 15th 2005 DRD Fixed iGetResponse to return proper last error information. Modified iFtpGet and iFtpPut to return the value 2 for probable success with futher information. Rev 44078 Sept 20th 2007 iHttpOpen will now write last error information out the wwwbatch.ini. Two possible keys are written out to the wwwbatch.ini: LastError and PreviousError. LastError gets updated each time the function is called. Possible values are either ‘No Error’or the error number that occurred along with the name of the function that failed. PreviousError contains unmodified last error number and function name. iClose was modified to throw error 346: Pending Data - Requires iReadData or iWriteData, if there is still data available to be read (i.e. iFtpCmd LIST command) . Fixed uninitialized string in iGetResponse. Rev 44079 Dec 16, 2008 DRF ADDED iFtpFileSize(conHandle, filename) Retrieves the file size of the requested FTP resource. Parameters: (i) conHandle - Connection andle returned from a call to iHostConnect. (s) filename - name of the file to delete on the remote system . Returns: (i) File size in bytes or -1 if file size is greater than 2 gigabytes. Note: iFtpFileSize currently only handles files files less than 2 gigabytes in size, results unreliable if > the 2 gigabytes. If the scheme name ("http://" or "ftp://") is missing this function will return @FALSE and iGetlastError will return 12006 (ERROR_INTERNET_UNRECOGNIZED_SCHEME). If the url specified does not exist this function will return @FALSE and iGetlastError will return 12007 (ERROR_INTERNET_NAME_NOT_RESOLVED) The server name could not be resolved. FIXED iClose not working properly if passed zero. Now iClose will return error 306 bad handle if passed a zero. FIXED iClose to only throw error 346: Pending Data - Requires iReadData or iWriteData, if there is still data available to be read (i.e. iFtpCmd LIST command) . FIXED iGetReponse. Increased returned string size from 256 to 4096. FIXED iFtpGet and iFtpPut to force values into iGetResponse. FIXED uninitialized string in first call to iGetResponse. iGetResponse now returns the string 'NONE' if no error condition exists. iFtpDirMake will return the error 318: iFtpDir_ function failed if the function fails to create the directory for any reason. WWWBATCH.INI is now placed in the [Application Data]\WinBatch\Settings directory, instead of in the Windows directory. You can obtain the [Application Data] directory using ShortCutDir function with the shell folder name 'AppData'. Added/updated WWWBATCH.INI error logging to the following functions: iAddr2Host iBegin iContentUrl iContentFile iCookieGet iCookieSet iDial iDialHangUp iDialItemize iGetConStatEx iGetIEVer iHost2Addr iFtpCmd iFtpDelete iFtpDirChange iFtpDirMake iFtpDirGet iFtpDirRemove iFtpFindInit iFtpFindNext iFtpOpen iFtpRename iHttpOpen iLocFindInit iLocFindNext iOptionGet iOptionSet iParseUrl iPing iReadData iReadDataBuf iUrlEncode iUrlDecode iWriteDataBuf Rev 44080 Mar 4, 2009 FIXED issue introduced in version 44079 that caused @HTTPS handles to throw 306 bad handle error. Rev 44081 Sept 7, 2011 64-bit port. Rev 44082 Jan 25, 2012 Modified "iFtpCmd" function to error instead of crashing when the function encounters a Windows 32-bit system bug while processing the "RETR" ftp command. Rev 44083 Sep 19, 2012 Modified iFtpDirMake by removing 318: iFtpDir_ function failed error and return zero upon failure. Rev 44084 July 24th 2013 Removed 318 error from iFtpDirRemove iFtpFileExist(conhandle, ftppath, ftpfilename) Checks if a file exists on the FTP server. iCheckConn(url) Allows an application to check if a connection to the Internet can be established. Parameters: (i) url - full url (i.e. 'http://www.windowware.com', 'ftp://ftp.windowware.com') . Returns: (i) @TRUE if a connection to the Internet can be established, @FALSE if not. If the scheme name ("http://" or "ftp://") is missing this function will return @FALSE and iGetlastError will return 12006 (ERROR_INTERNET_UNRECOGNIZED_SCHEME). If the url specified does not exist this function will return @FALSE and iGetlastError will return 12007 (ERROR_INTERNET_NAME_NOT_RESOLVED) The server name could not be resolved. Rev 44085 Dec 18th 2013 Fixed iGetIEVer() returning invlaid verson number on IE 10 and newer. Starting in IE 10 there is a new svcVersion value found under "HKLM\SOFTWARE\Microsoft\Internet Explorer". Rev 44086 Sept. 3, 2014 Fixed multiple bugs in the iOptionSet function that made it impossible to set and use the client_cert_context option. Rev 44087 Sept. 14, 2016 Removed returned total header size limit in the iHttpHeaders function. Rev 44088 Mar. 20, 2018 Made the 64-bit version of the extender Large Address Aware compatible.
Article ID: W12590
Filename: !NEWSFLASH!.txt
File Created: 2018:03:20:10:54:58
Last Updated: 2018:03:20:10:54:58