Re: HTTP Testing Resources

Mark Nottingham <mnot@mnot.net> Tue, 09 April 2019 00:15 UTC

Return-Path: <ietf-http-wg-request+bounce-httpbisa-archive-bis2juki=lists.ie@listhub.w3.org>
X-Original-To: ietfarch-httpbisa-archive-bis2Juki@ietfa.amsl.com
Delivered-To: ietfarch-httpbisa-archive-bis2Juki@ietfa.amsl.com
Received: from localhost (localhost [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id C5E4512000F for <ietfarch-httpbisa-archive-bis2Juki@ietfa.amsl.com>; Mon, 8 Apr 2019 17:15:41 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -2.999
X-Spam-Level:
X-Spam-Status: No, score=-2.999 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, HEADER_FROM_DIFFERENT_DOMAINS=0.001, MAILING_LIST_MULTI=-1, SPF_PASS=-0.001, URIBL_BLOCKED=0.001] autolearn=ham autolearn_force=no
Authentication-Results: ietfa.amsl.com (amavisd-new); dkim=pass (2048-bit key) header.d=mnot.net header.b=Cedb/Leu; dkim=pass (2048-bit key) header.d=messagingengine.com header.b=C1KJk3Yc
Received: from mail.ietf.org ([4.31.198.44]) by localhost (ietfa.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id Q7egagsyjd5V for <ietfarch-httpbisa-archive-bis2Juki@ietfa.amsl.com>; Mon, 8 Apr 2019 17:15:38 -0700 (PDT)
Received: from frink.w3.org (frink.w3.org [IPv6:2603:400a:ffff:804:801e:34:0:38]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ietfa.amsl.com (Postfix) with ESMTPS id 62B941200E5 for <httpbisa-archive-bis2Juki@lists.ietf.org>; Mon, 8 Apr 2019 17:15:37 -0700 (PDT)
Received: from lists by frink.w3.org with local (Exim 4.89) (envelope-from <ietf-http-wg-request@listhub.w3.org>) id 1hDeOX-0003kS-2j for ietf-http-wg-dist@listhub.w3.org; Tue, 09 Apr 2019 00:13:45 +0000
Resent-Date: Tue, 09 Apr 2019 00:13:45 +0000
Resent-Message-Id: <E1hDeOX-0003kS-2j@frink.w3.org>
Received: from mimas.w3.org ([2603:400a:ffff:804:801e:34:0:4f]) by frink.w3.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.89) (envelope-from <mnot@mnot.net>) id 1hDeOV-0003je-N1 for ietf-http-wg@listhub.w3.org; Tue, 09 Apr 2019 00:13:43 +0000
Received: from out5-smtp.messagingengine.com ([66.111.4.29]) by mimas.w3.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.89) (envelope-from <mnot@mnot.net>) id 1hDeOU-00038a-A7 for ietf-http-wg@w3.org; Tue, 09 Apr 2019 00:13:43 +0000
Received: from compute3.internal (compute3.nyi.internal [10.202.2.43]) by mailout.nyi.internal (Postfix) with ESMTP id 6BCB021B2F; Mon, 8 Apr 2019 20:13:20 -0400 (EDT)
Received: from mailfrontend2 ([10.202.2.163]) by compute3.internal (MEProxy); Mon, 08 Apr 2019 20:13:20 -0400
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=mnot.net; h= content-type:mime-version:subject:from:in-reply-to:date:cc :content-transfer-encoding:message-id:references:to; s=fm2; bh=d 3p0QijQ9tqO9QlcqE8OivBgzVpEYTD4xg8EzDZKYiM=; b=Cedb/LeuUhkKdSKph 8gu68orYO2H36o5akNPmUMdHyAtB1555gehfnTLNdVeID284iuWNbR9i3U5rRpxS OSb0O3j4aD3ROkQ40CL5G9/ptFJej3uX4zrltNNkjj+U3LWcmdlgny6K7ys901R1 gxfBWHz5CGj4rJcWkHAkrqJQc1KOU9rCGdJ5NEE09dWeLi6rRy4RnPYWV2CICfCQ PAeCkapgUQX+SIXYjF5arZEhNAh+7nUgrFnYQqRLaMrWCp85Wx3blAWBhGzjfXGX J/4uGrAlGrgG7MYnua0ZrQvAGM4IDhcDuSFl3V9Oo8ZOWMPS3HgvVzRGi101kXSD EuyAQ==
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:content-transfer-encoding:content-type :date:from:in-reply-to:message-id:mime-version:references :subject:to:x-me-proxy:x-me-proxy:x-me-sender:x-me-sender :x-sasl-enc; s=fm2; bh=d3p0QijQ9tqO9QlcqE8OivBgzVpEYTD4xg8EzDZKY iM=; b=C1KJk3YckhwehhVtte5Sx2qoIWSTfQjc/QajRnDbM/7yRkF47aJoXPAI+ loBKVTrf2hmhHmyTdbXyFYJE3Ih0tMhVD1eMiuxu3TcnCqYp1OR8LCYrdLJuFZN3 o7FIClUjOItaqYtdXHj31z3CWIEqU3Bi5qHVGB/1UTtD8S8ksekKSTqPVl3jrWm1 ZdnIEAloCKqSmJ2JbZhUT6R/+ghPsBhZQx/BSUBpHVpHVanAP89N+19oNsASl8oK 4awH4EykEQs9x+bbTByHi8RLG/b9zzq/IlnOANv0VaFRX3vM37vQaFxjl5J92sWc FHnWhQBHQFajXBDNTpYBGTMLbYDYA==
X-ME-Sender: <xms:n-OrXG7xAIWj6vqEmR8da_0At64OV5HoF2Ai57IAgvegpc3xAqreWA>
X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgeduuddrudeggddvlecutefuodetggdotefrodftvf curfhrohhfihhlvgemucfhrghsthforghilhdpqfgfvfdpuffrtefokffrpgfnqfghnecu uegrihhlohhuthemuceftddtnecunecujfgurheptggguffhjgffgffkfhfvofesthhqmh dthhdtvdenucfhrhhomhepofgrrhhkucfpohhtthhinhhghhgrmhcuoehmnhhothesmhhn ohhtrdhnvghtqeenucffohhmrghinhepghhithhhuhgsrdgtohhmpdhmnhhothdrnhgvth enucfkphepudeggedrudefiedrudejhedrvdeknecurfgrrhgrmhepmhgrihhlfhhrohhm pehmnhhothesmhhnohhtrdhnvghtnecuvehluhhsthgvrhfuihiivgeptd
X-ME-Proxy: <xmx:n-OrXDlaVgbFfyi58uwnvgjxx8ExQs0CtGEtgghBTurvrvtu1q5gOw> <xmx:n-OrXAiusdgQfk4Uj__ny5NPMOoNZEdkusdmYzSa2QIPooweUJfpTw> <xmx:n-OrXAkp2wAuswpeDopJUlWkIpga6u0GyAJNNhmmcKVr03LfHV6SSQ> <xmx:oOOrXKnxSpq3PH3dRGXCRcF6ch3PaYddJupA8y2dj9Bxpi5JFqGthg>
Received: from attitudadjuster.mnot.net (unknown [144.136.175.28]) by mail.messagingengine.com (Postfix) with ESMTPA id 5F8ED10319; Mon, 8 Apr 2019 20:13:18 -0400 (EDT)
Content-Type: text/plain; charset="us-ascii"
Mime-Version: 1.0 (Mac OS X Mail 12.2 \(3445.102.3\))
From: Mark Nottingham <mnot@mnot.net>
In-Reply-To: <CALOnmf9u8O8tXOHbdGycBY2uzLkdTOcaA3m867AOnJP5NRgFwA@mail.gmail.com>
Date: Tue, 09 Apr 2019 10:13:15 +1000
Cc: "ietf-http-wg@w3.org Group" <ietf-http-wg@w3.org>
Content-Transfer-Encoding: quoted-printable
Message-Id: <E8AC9365-7EF2-442D-A1C0-E20B13E3C449@mnot.net>
References: <5D06B498-B7C4-4F82-9935-D7D95D9DC6A9@mnot.net> <CALOnmf9u8O8tXOHbdGycBY2uzLkdTOcaA3m867AOnJP5NRgFwA@mail.gmail.com>
To: Sawood Alam <ibnesayeed@gmail.com>
X-Mailer: Apple Mail (2.3445.102.3)
Received-SPF: pass client-ip=66.111.4.29; envelope-from=mnot@mnot.net; helo=out5-smtp.messagingengine.com
X-W3C-Hub-Spam-Status: No, score=-6.4
X-W3C-Hub-Spam-Report: AWL=3.440, BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_LOW=-0.7, SPF_HELO_PASS=-0.001, SPF_PASS=-0.001, W3C_AA=-1, W3C_DB=-1, W3C_IRA=-1, W3C_IRR=-3, W3C_WL=-1
X-W3C-Scan-Sig: mimas.w3.org 1hDeOU-00038a-A7 0d7ce9004eee5400e07f0c02c3c4fef9
X-Original-To: ietf-http-wg@w3.org
Subject: Re: HTTP Testing Resources
Archived-At: <https://www.w3.org/mid/E8AC9365-7EF2-442D-A1C0-E20B13E3C449@mnot.net>
Resent-From: ietf-http-wg@w3.org
X-Mailing-List: <ietf-http-wg@w3.org> archive/latest/36508
X-Loop: ietf-http-wg@w3.org
Resent-Sender: ietf-http-wg-request@w3.org
Precedence: list
List-Id: <ietf-http-wg.w3.org>
List-Help: <https://www.w3.org/Mail/>
List-Post: <mailto:ietf-http-wg@w3.org>
List-Unsubscribe: <mailto:ietf-http-wg-request@w3.org?subject=unsubscribe>

Hi Sawood,

That sounds interesting; have you published them yet? If so, I don't see any harm in adding them.

For what it's worth, the approach you outline reminds me of how cache-tests.fyi works; it defines test cases in JavaScript data structures, and you can run them using a NodeJS CLI or in a browser. 

Also, part of the problem of server testing is that many behaviours are dependent upon a particular resource, because of how it interfaces with the server (filesystem vs. CGI, for example) and also because of resource-specific handling. REDbot tries to address that by running checks against individual URLs, but I think there's also space for a tool that can be used to check how "back-ends" such as filesystems, CGI, FastCGI, as well as Web frameworks (e.g., Drupal, Wordpress) handle various aspects of the protocol.

Cheers,


> On 9 Apr 2019, at 10:03 am, Sawood Alam <ibnesayeed@gmail.com> wrote:
> 
> Hi,
> 
> Last year I wrote a web server tester library along with a handful of custom test suites to automate testing/grading of students' assignments of the Web Server Design course. While I think it is relevant here, I would wait for some feedback before I decide to add it to the wiki. Here is how it works:
> 
> First, write a template file (say, "malformed-header.http") for the request data (which can be a single HTTP message or multiple messages put together for pipeline requests) as following:
> 
> GET /foo HTTP/1.1
> Host: <HOSTPORT>
> Header with missing colon
> 
> Then write a test method in a test suite class, inherited from the base tester class, as following:
> 
> @make_request("malformed-header.http")
> def test_bad_request_header(self, report):
> """Test whether the server recognizes malformed headers"""
>     self.check_status_is(report, 400)
> 
> From there, the test can be run against any HTTP server using the included CLI or Web UI.
> 
> I am planning to improve it further when I will offer this course in the Fall 2019.
> 
> Best,
> 
> --
> Sawood Alam
> Department of Computer Science
> Old Dominion University
> Norfolk VA 23529
> 
> 
> 
> On Mon, Apr 8, 2019 at 7:43 PM Mark Nottingham <mnot@mnot.net> wrote:
> Hi everyone,
> 
> We've started collecting resources that might be helpful to test HTTP implementations here:
>   https://github.com/httpwg/wiki/wiki/HTTP-Testing-Resources
> 
> Thoughts / additions?
> 
> Cheers,
> 
> --
> Mark Nottingham   https://www.mnot.net/
> 
> 

--
Mark Nottingham   https://www.mnot.net/