rewrite http eascape and unescape