Re: matching pictures w/ mime

From: Carlos G Mendioroz (tron@huapi.ba.ar)
Date: Sat Oct 02 2004 - 08:06:38 GMT-3


Given that you could not got it to work, I would get suspicious about it
being right :-)

As I pointed out before, there is no mime content type that ends with
jpg. The content type is "image/jpeg" in the case of JPEG encoded images.

Pay attention to the direction of traffic that you apply the filter to.
GETs (from browser to server) are the ones carrying the URL, so the ones
that you can you can filter with URL.
Responses are the ones carrying content and content type header, where
the MIME filter works.

Some labs just don't pay attention to this and ask you to filter such
and such, leaving to your imagination where clients (browsers) and
servers are...

-Carlos

none wrote:

> Hi John,
> Although I have not yet gotten it to work, I've been using the
> following for matching mime type image:
>
> match protocol http mime "*gif"
> match protocol http mime "*jpg"
>
> As I understand it, this will get the job done. When asked to get rid of
> GIFs, JPGs or whatever, I've just recently started using the following (and
> this does in fact work):
>
>
> class-map match-any IMAGES
> match protocol http url "*.gif"
> match protocol http url "*.jpg"
> match protocol http mime "*gif"
> match protocol http mime "*jpg"
> !
> !
> policy-map QOS
> class IMAGES
> drop
>
>
> Cisco offers the following example:
>
> <snip>
> The following example classifies, within class map foo, packets based on the
> JPEG MIME type:
>
> class-map foo
> match protocol http mime "*jpeg"
>
> </snip>
> http://www.cisco.com/en/US/products/sw/iosswrel/ps1838/products_feature_guid
> e09186a0080134add.html
>
>
> Also:
> http://www.cisco.com/en/US/products/sw/iosswrel/ps1835/products_tech_note091
> 86a0080110d17.shtml
>
>
> In addition, Scott and some others hashed this out very recently, the title
> of the thread was "RE: MQC to filter MIME-types" - check the archives
>
> HTH
> Alsontra
>
>
>
>
>
> -----Original Message-----
> From: nobody@groupstudy.com [mailto:nobody@groupstudy.com] On Behalf Of John
> Matus
> Sent: Friday, October 01, 2004 5:43 PM
> To: lab
> Subject: matching pictures w/ mime
>
> is this the correct syntax for matting images with mime?
>
> class-map match-all image
> match proto http mime "image/*"
>
> i'm used to matching with 'http url "*.jpg*", so i want to make sure the
> syntax is right.
>
>
> Regards,
>
> John D. Matus
> MCSE, CCNP
> Office: 818-782-2061
> Cell: 818-430-8372
> jmatus@pacbell.net
>
> _______________________________________________________________________
> Subscription information may be found at:
> http://www.groupstudy.com/list/CCIELab.html
>
> _______________________________________________________________________
> Subscription information may be found at:
> http://www.groupstudy.com/list/CCIELab.html
>

-- 
Carlos G Mendioroz  <tron@huapi.ba.ar>  LW7 EQI  Argentina


This archive was generated by hypermail 2.1.4 : Sat Nov 06 2004 - 17:11:42 GMT-3