http decoder base code