simple callback-based HTTP request/response parser