move canonicalizer code out (as now in addressing package)