Add HTTP server and complete ProtocolRedirect test

See commits for detail.