Make the CH middleware actually work. Needs a bit of a hack to route
the fake version.bind and friends zone to the correct handler. Fiddle
with the order in directive.go so that CH queries get logged as well.
Secondly add class rewriting to the rewrite middleware handler and also
log the class by default.