If I am understanding your question properly, you are serving static files and want to be able to do processing on a static file request in order to decide whether or not the user has access to that file. (based on MIME type)
If you map all files requests through a custom IHttpHandler (see the handlers section of your web.config file), you should be able to accomplish this.
In ProcessRequest (or BeginProcessRequest if you implement an asynchronous handler), you can call HttpContext.Current.Server.MapPath("~" + HttpContext.Current.Request.Path) (might be a better way to do that) to get the current static file being requested.
You can then analyze the extension of that file to make your decision.
Not sure if thats what you want, but hopefully it helps