Old Proxomitron Forums

Proxomitron Filters - Discussions welcome => Other => Topic started by: pooms on June 12, 2002, 08:18:44 PM

Title: Enabling filtering of text/xml
Post by: pooms on June 12, 2002, 08:18:44 PM
It took me a long time to figure out how to apply content filters
to text/xml documents, so just in case anyone else is as dumb
as me, you have to first create a header filter for the Content-type
that explicitly enables filtering. Something like this:

Key = "Content-Type: Enable text/xml filtering (In)"
Match = "(text/xml)&$FILTER(true)"
Replace = ""

There are a few other xml related content types that I probably want to
enable (eg application/xml, application/soap), so it will probably make
sense to expand this to use a LST of content types to enable.

Title: Enabling filtering of text/xml
Post by: sidki3003 on June 12, 2002, 08:36:06 PM
The list where you can append to, might be already there (MIME Fix List).
But you would have to allow for changing the mime type to text/html.
There was a discussion about this here:

Title: Enabling filtering of text/xml
Post by: Jor on June 12, 2002, 08:37:20 PM
Hmm... I won't be using this filter, actually.

The only XML documents I've found so far that are meant to be watched in a web browser are XHTML documents on websites like the MSDN or Opera.com , and they do not use ads.

Other XHTML documents are served as text/html, and thus will be filtered.

Using the Proxomitron will destroy valid XML documents (at least in MSIE, Opera seems to recognise the actual XML and still displays it somewhat correctly), so it is not advisable to use it for all cases.

How about adding a blocklist to it, so it is only triggered for needed sites?

Title: Enabling filtering of text/xml
Post by: pooms on June 12, 2002, 11:02:17 PM
I probably should have explained why I was doing this!  I didn't mean
to imply that this filter would be good to enable for general browsing.
I'm not even going to use this in my normal configuration, but in a special
one that I will use for a very specific purpose.

I'm going to use it for non-browser, peer-to-peer web services,
where XML messages are being sent within SOAP envelopes
over HTTP. In this case, I wrote the SOAP sending and receiving code,
so I know exactly what is being sent and what filters I should or shouldn't
have enabled. I also cannot change the Content-type value, because
the receivers of the SOAP/XML messages explicitly check that value and
would reject anything like text/html.

Sorry I didn't explain myself more clearly. I was only trying to show the
concept of having to explicitly turn on filtering for Content types outside
the core set. I spent several frustrating hours trying to get filters to
apply to text/xml contents before concluding that it wasn't my filters
that were wrong, it was that no filters at all were being applied to text/xml
contents. Then it took quite a while before I finally found the hint that
I needed in the "Limitations" section of the Proxomitron help pages.

Title: Enabling filtering of text/xml
Post by: Jor on June 13, 2002, 12:18:51 AM
Okay :)

You're of course right, for that purpose this is a good filter.