Using IIS7 URL Rewrite with ColdFusion 9

I was wondering if someone could help to utilize the IIS 7 URL Rewrite Mod to process pages in the following manner. I’ve done some Google searches, but the articles that explain the system seem above my comprehension at the moment.

I’m trying to get SES URLs that look/work like this:

http://www.domain.com/[[B]folder[/B]]/[file]/[optional value1]/[optional value2]/[etc…]

Any page not found would redirect to http://www.domain.com/index.cfm?$404=[[B]path provided[/B]] (but in the browser URL it would show the pretty URL)

So if I went to:

www.domain.com/blog/latest/2010/january/18

it would redirect internally to

www.domain.com/index.cfm?$404=/blog/latest/2010/january/18

From there I can use ColdFusion to parse the $404 URL variable and determine if folders/files exist and build the page, I just can’t get the rewrite rules down pat.

The ColdFusion would ensure legit characters would used and would determine (ok, for the ‘latest’ page in the ‘blog’ folder, I’m expecting up to 3 URL values provided, the first is URL.year, the next URL.month and the last URL.day, and I’d write the code so it would create and set those URL variables to be available for the request.

Can someone help me with the rewrites?