System and method for modifying web content via a content transform proxy service
The Content Transform Proxy (CTP) service is an advanced Web proxy service, the basic function of which is to modify incoming HTTP requests having a server-side destination and/or outgoing HTTP responses. The CTP service is implemented by the CTP program, which resides on a host in a data communications network between an end user (the Web client) and a content server that the client is attempting to access. The HTTP request and/or an HTTP response is modified by making an HTTP request on the client side using a client web browser, processing the HTTP request on the server side using outgoing proxy rules, passing on the processed HTTP transaction to the server-side destination, returning the results of the processed HTTP request from the server-side destination, processing the HTTP response on the server side using incoming proxy rules, and returning the processed HTTP response to the client web browser on the client side.
1. A method of modifying at least one of an HTTP request and an HTTP response during a web transaction having a client side and a server side, comprising the steps of:
making an HTTP request on the client side using a client Web browser, the HTTP request having a server-side destination;
processing the HTTP request on the server side using outgoing proxy rules to determine whether to modify the HTTP request;
passing on the processed HTTP transaction to the server-side destination;
returning results of the processed HTTP request from the server-side destination;
processing the HTTP response on the server side using incoming proxy rules to determine whether to modify the HTTP response;
returning the processed HTTP response to the client web browser on the client side;
setting up a sequence of filtering streams;
reading one of the filtering streams;
building a window of operation containing possible text of interest when one of the streams is read, wherein at least one regular expression is used to define a corresponding at least one rule that in turn defines the text of interest and actions required on the text of interest;
creating a buffer by comparing the possible text of interest with text bounding the possible text of interest;
determining whether the buffer matches a predefined condition; and
when the buffer matches the predefined condition, handing off the buffer to another entity responsible for running the at least one regular expression.