BunnyX

An XML Proxy Server that dynamically creates an XML based API from existing web applications

BunnyX History.

A long time ago, in an Internet far far away, the openness of the World Wide Web was being taken over by proprietary file formats and HTML tags. This made writing web applications hard and using them in a cross-platform manner even harder, until XML. XML is a file format that everyone can understand. Interpreting XML is quite different from representing data in it (which is something its cousin HTML does visually rather well). The problem with a new format is that it's hard to teach some old applications new protocols.

Everything in computer science, be it hardware or software, can be broken down into the three P's: Protocol, Personalization and Proxy. I have been writing various types of proxy applications for some time either as new APIs to map to old (a javascript library I wrote to create DOM Level 1 type access to NS4 browsers for example) or literal proxy applications (such as a horrendous VB6 Proxy I wrote called VBProxyPlus that basically let me use applications which didn't support NTLM to authenticate against a MS proxy so as to get access to the web. Some low version of Mozilla at the time was my impetus).

Very few proxy applications and uses I encountered modified data at a network application level, notable exceptions including anonymizing proxies and data compression proxies (which I will come back to). One day, I had a problem, I wanted to know how much time I had spent online with my ISP and they provided a spiffy web interface (ok not that spiffy, but working) for me to use. The real problem was, I didn't really want to know how much time I had spent online, but how much I had left. More useful was how much time on average I had left per day if I was to keep within my subscribed number of hours. To do this, I did what is common practice when dealing with a web application, I wrote some simple screen scraping code and applied some regular expressions to extract the relevant output, created a nice SWING GUI and viola, I kept track of my time down to being able to keep exactly 1 minute under my limit.

During this time, I was also pursuing my M.Sc. degree at the local university, running though courses like mad and quite unemployed. I decided to find an open source application that interested me and possibly sell services based on setting it up, supporting it etc. The application that caught my eye was a Java based proxy named Rabbit. It was a dynamic data compression proxy that also did image manipulation on the fly to make web pages load faster for clients that supported the compression protocol (which most, if not all modern browsers did). So I went to an ISP (not my own ironically) and talked to the network guy there who, after I harassed him thoroughly insisted that since there were clients that may not support the compression, he couldn't daisy chain it to the proxies already there. Not having access because of the proxy might cause the company to upset or lose customers. A very valid point, so I decided to write a PHP front end for Rabbit that relayed all HTTP requests through it. Fine in theory, but not so good in practice. The major problem was that websites that generated HTML with relative URLs (which most do) stopped working as the path relative to my PHP script was not the right path to the page being linked to. So, I wrote a proxy that prepended (I know, not a word) a string to every attribute storing a URL as defined by the HTML 4.0 Spec. That proxy and its PHP front end was BunnyX 0.1.

Subsequently, during my course of study, I forgot all about selling Rabbit and BunnyX and decided that my new proxy would make an excellent test implementation of a feasibility study I was carrying out to determine, based on the best design I could come up with, just how feasible it would be to provide XML based services and data dynamically from existing web applications. I included in my thesis, test results determining expected performance hits for using the proxy under a particular load with different levels of XML being generated. The software used to generate this data, BunnyX, has now been released.

- Christopher Ottley

Php Logo   SourceForge Logo