# Libwww Release Notes

This page describes the new features and bug fixes for all libwww releases. The list also includes the latest changes that are committed to and available from CVS but not yet in a release.

## Release 5.1n (To be released)

These are the things that are upcoming in the next release. Also check out the the latest changes in the CVS repository.

### New Features

- Added a method in the HTAccess API for posting forms and returning the response as a HTChunk object
- Added handler for unknown content encodings in the Command Line tool to be a through line (identity decoding) using the best matching mechanism
- Added support for regex handling of proxies so that you can now say something like this: all URIs matching this regex goes to this proxy, all others go to this, etc.
- Better control of how much data is being sent in the . Now you can both get the total number of bytes read and written as well as the number of entity (body) bytes read and written. This uses features provided by the HTNet object
- The default implementation of progress notifications now uses the new HTRequest bytes read/written methods.
- The mime parser in HTMIME.c and HTMIMERq.c now uses the updated control of bytes read/written.
- Added support for version conflict detection in Web Commander (update all of WinCom area)
- The Web Commander - the Win32 GUI PUT sample application has been updated from the ground up - try it out!

### Bug Fixes

- Remove access authentication credentials duplicates when doing the HTSaveFilter on the same resource
- Checks that etags are not the same when setting a new one. This caused first the old (which was also the new) to be deleted and then created again.
- Fixed HTTP POST problem where small post data didn't always get posted. This affects several files including HTMIME.c and HTMIMERq.c
- Fixed HTTP PUT problem when a 100 Continue code came more than 2 secs after the request.
- Added interrupt alert message to HTTP.c
- Added alert message when status is 503 Retry to the information filter in HTFilter.c
- The last modified time is now stored in the anchor object when opening a local file
- Added support for preconditions in the save document calls in HTAccess
- Deleted unused variable in HTBufWrt.c
- Fixed typo in function prototype in HTResponse.html
- Made `WWW_TraceFlag` unsigned integer in HTUtils.html (was signed) and changed order in wwwsys.html so that netinet/in.h now is included before netinet/tcp.h in wwwsys.html. This was a problem on RC6000.
- Put in a few checks for invalid function arguments (NULL etc.) in HTEscape.c and HTParse.c
- Added explicit support for HTTP preconditions (the if-* headers) so that they can now be turned on and off on a pr request basis. This affects HTReqMan.c HTReq.html and HTReqMan.html
- Changed the encoding streamstack builder to support best matching (wildcard matching) capabilities. This means that you now can register a default decoder like this: `HTFormat_addCoding("*", HTIdentityCoding, HTIdentityCoding, 0.3)`, for example where `HTIdentityCoding` is a coder provided by libwww. The quality indicates how much you like it (between 0.0 and 1.0)
- Now also removes the after authentication filter is all proxies are unregistered
- Changed the progress notifications in HTAlert to also include Interrupted! This affects HTCache.c (a little), HTAlert.html (and .h), and HTDialog.c
- Moved the increment of bytes written (used in PUT) from the buffered output steam to the unbuffered output stream which gives a more accurate reading.
- Bad typo bug when deleting before filters in HTNetCall_addBefore which caused deletion problems in the Filter list
- Fixed a problem when PUT'ing to a non-existent host (or invalid portnumber) in the Save Filter. The cleanup is now made more cleanly.
- Moved the Done! progress notification into HTMIME.c instead of in HTReader.c as it no longer has much to do with closing the TCP connection.
- Made sure that local files are closed when using ANSI C file descriptors
- Fixed bug in the conversion from URI to local Windows file in HTWWWToLocal()
- Fixed problem in the template generation in the access authentication module. This can cause the authentication module to not find the credentials already given.
- Fixed strange deletion of semaphore control for non-persistent connections
- A close socket event wasn't registered on Windows. This is now done in HTHost.c.
- On some platforms, it is not possible to refer to function addresses across shared libraries. The result is that the libwww API that uses function addresses don't always work. I have added an opcode version of the HTAlert API to handle this for user messages and progress notifications.

## Release 5.1m May 21, 1998

### New Features

- Changed the encoding streamstack builder to support best matching capabilities. This means that you now can register a default decoder like this: `HTFormat_addCoding("*", HTIdentityCoding, HTIdentityCoding, 0.3)`, for example where `HTIdentityCoding` is a coder provided by libwww.
- Added support for writing out `Link:` header fields when uploading a document. The `Link:` header field is use to represent link relationship between documents
- Changed HTEscape to deal with silly MSDos file type escaping of the drive name (using ":").
- Added support for automatic authentication (!) in the Command Line Tool so that it is now possible to authenticate from scripts etc.
- Direct access to the CVS repository - checkout libwww and work with the latest version!
- Made sure that we write more often as we check for expired timers in HTWriter.c
- Added a "repetitive" flag to timers so that they can be created to say call me every 30ms over and over again
- Added support for building libwww as a shared library on Unix (it is already using DLLs on Windows). If you have any problems with shared libraries on your platform then run configure with the `--disable-shared` flag and you will only get the static version. If you are using libwww as a shared library but do not use the libwww HTML parser then you MUST include this dummy implementation of the HText interface somewhere in your code. The reason for this is that the HText interface may be called (it depends a bit on how your platform supports shared libraries) but an implementation isn't provided.
- Added support for MySQL access in this simple SQL interface which takes care of most os the common problems encountered when talking to an SQL server. Currently I use this for handling logging in the webbot but many other features like persistent caching, preferences, etc. can use the SQL module as well. You can also see some cool examples of how to use the robot's logs when querying MySQL through www-sql.
- Changed the name of "`config.h`" to "`wwwconf.h`" as the first name caused conflicts with other packages
- Changed the name of "`sysdep.h`" to "`wwwsys.h`" for the same reason

### Bug Fixes

- Fixed a bug in the generation of relative URIs which caused the creation of incorrect relative URIs. Libwww uses relative URIs in the HTTP referer field and other places to save (often significant) amount of bandwidth.
- Decreased default max number of outstanding (pipelined) requests from 100 to 50
- Does now check whether we get a broken pipe when writing to the network from expired timers. This was a bug that it didn't.
- Applied the following patches
- Fixed a problem in the HTWWWStr.c that caused a Y2K bug if strftime isn't available on the system on where libwww is running

## Release 5.1l March 25, 1998

This is a small add-on to 5.1k that was released two days ago. It has a few fixes that was discovered while working with the latest Arena browser.

### Bug Fixes

- Minor stuff that made PUT work nicer from a user perspective (when to ask what questions, etc)
- Fixed a few things in the direct WAIS access module

## Release 5.1k March 23, 1998

### New Features

- Added a simple "single user lock" on the persistent cache as it gets confused if multiple users are using it.
- On Unic, the header files are now installed when running "`make install`". The default location is `"/usr/local/include/w3c-libwww`".
- On Unix, aset of icons that can be used when browsing local file directories are also installed - the default location is "`/usr/local/share/w3c-libwww`"

### Bug Fixes

- These are the patches that I have received for the current release. They will be applied to this upcoming release.
- Fixed a few bugs that make Arena run on top of the latest version

## Release 5.1j March 9, 1998

### New Features

- Made the distinction between Transfer-Encoding and Content-Transfer-Encoding clear - they were somewhat mixed up before. Libwww also now supports multiple transfer-codings as well as multiple content-codings as required by HTTP/1.1.
- Changed the Stream Stack to not call the `SaveLocally` stream any more but instead return an ErrorStream. The reason for this is that there are several places in the stram stack building algorithm where we might want to save the file to local file: when there is a content type that we don't understand, a content-encoding, or a transfer-encoding (or a combination of these) that we don't understand. Now we can make sure that the `SaveLocally` stream is only called once
- Added support for "identity" transfer-coding and content-coding
- Added support for Allow header when doing PUT and POST

### Bug Fixes

- Fixed a problem handling wrong HTTP responses from NCSA HTTPD derived servers (they don't include a version number when responding to an HTTP/1.1 request)
- PUT now works much more reliable, and it also works on Windows (at least NT, I haven't tested it on 95).
- Fixed a refresh problem in the Line Mode Browser which caused it to sometimes render the screen twice.

## Release 5.1f January 1998

### New Features

- Changed the referer HTTP header field to use relative URIs instead of absolute. This saves a lot of bytes on the wire
- Added support for logging the charset media type parameter
- Added support for logging when the ALT tag is missing from inlined images
- Extended the log class to support arbitrary log files

### Bug Fixes

- Fixed some problems in the HTRelative function in HTParse.

## Release 5.1e January 1998

### New Features

- Added support for linking against a POSIX Regular Expression (regex) library. This is used in the Robot, for example, to support regular expressions on URIs to include and exclude from a traversal. The code has been tested with the GNU regex library.
- Added more logging features to the webbot

### Bug Fixes

- Fixed bug in ouputstream that caused buffer to be overwritten in some cases when blocked on write

## Release 5.1d December 1997

### Bug Fixes

- Lots of bug fixes in the pipelining code and increased performance

### New Features

- Better logging facilities with support for multiple log objects including referer logging, Common Log File format logging and general logging filters.

## Release 5.1c September 1997

- Lots of bug fixes

## Release 5.1b April 1997

### Bug Fixes

- Fixed a problem in HTRules.c as described in this bug report
- Fixed coredump problem in HTGetTmpFileName() as described in this bug report. This affects also the HTCache module which relies on temporary file names
- Made the persistent cache more robust which in some cases will save a segmentation fault
- Fixed problem in wwwsys.h as reported in this bug report
- Fixed problem where a request was not flushed if using blocking sockets as reported by this bug report.
- A limitation in the current persistent cache is that it only works in non-preemptive mode. Hence if using blocking sockets then the cache should be disabled. This is now the default behavior in the libwww profiles.
- Bug fixed that caused the `maxsock` variable used in `select()` not to be decreased when deleting a socket in the default event manager
- Changed the connection management so that it complies with the Connection Management draft by Jim Gettys and Alan Freier. The HTTP client now closes idle connections after 60 seconds which is a heuristic period chosen by Jeff Mogul in the paper "The Case for Persistent-Connection HTTP". The number can be dynamically changed using the `HTHost_setPersistTimeout()` and the `HTHost_persistTimeout()` methods. This could be made more advanced so that we take into account any information given in the "`Keep-Alive`" header but isn't for now.
- Fixed a problem when a HTTP/1.1 server sent a response including a `Connection: close` header using the close of the TCP connection as a delimiter. This problem was pointed out in this bug report
- Fixed security hole handling HTTP 305 proxy redirection codes. The proxy location returned in the responses was enabled as a permanent proxy without any notification. The operation now requires explicit acknowledgement from the user
- Fixed potential (but small) security whole handling parsing a new rules file. This operation now requires explicit acknowledgement from the user.

## Release 5.1 February 18 1997

### New Features and APIs

- Added support pipelining
- Support for zlib based decompression in content encoding

### Bug Fixes

- A whole bunch of them...