From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: =?UTF-8?Q?Aleix_Conchillo_Flaqu=C3=A9?= Newsgroups: gmane.lisp.guile.devel Subject: Re: [PATCH] web: authorization header scheme should be capitalized Date: Thu, 23 Jun 2022 13:42:14 -0700 Message-ID: References: <20220623202759.3578506-1-aconchillo@gmail.com> <922957d6545149287a6aec7b9d258bf2dd7603ef.camel@telenet.be> Mime-Version: 1.0 Content-Type: multipart/alternative; boundary="000000000000c041cc05e2237d7e" Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="10888"; mail-complaints-to="usenet@ciao.gmane.io" Cc: guile-devel To: Maxime Devos Original-X-From: guile-devel-bounces+guile-devel=m.gmane-mx.org@gnu.org Thu Jun 23 22:43:19 2022 Return-path: Envelope-to: guile-devel@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1o4Tfa-0002cx-FR for guile-devel@m.gmane-mx.org; Thu, 23 Jun 2022 22:43:18 +0200 Original-Received: from localhost ([::1]:59716 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1o4TfY-0000GI-W5 for guile-devel@m.gmane-mx.org; Thu, 23 Jun 2022 16:43:17 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:44934) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1o4Tf2-0000Fc-KL for guile-devel@gnu.org; Thu, 23 Jun 2022 16:42:46 -0400 Original-Received: from mail-pg1-x533.google.com ([2607:f8b0:4864:20::533]:37792) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1o4Tf0-0006kv-D3 for guile-devel@gnu.org; Thu, 23 Jun 2022 16:42:43 -0400 Original-Received: by mail-pg1-x533.google.com with SMTP id h192so522132pgc.4 for ; Thu, 23 Jun 2022 13:42:26 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=nutwB+ovVSTDlzGWQIq+7yCr9Sg+31F7/dz/czLhgcU=; b=Do6Ca81woSdtFhM5z3/7txo7htaPZIbljYkpicMrF29yNPmbDrYhemrZu6ygZkDG1Y JHf8ixQcEqk0Gag/sShC5RipsvhRAVgj4lAiYy7kNQwe4SpA0LRrDUYHPUXu7Yl7aDb5 2xX9MJ4PKwprQrUnzLGezsXWZwERAxGI2PB2kLJTGyLZAgTGiaKr+iU1f4NFVswCjXBL AI9zCKluE05RbIFCTafn6qL08rI05jhOmha+hYG09XvylDEz18tGQYqoZxACf50dMLj2 JApBtb1IsjJWOkIz83s9s+yQNQUEeo5izeaU369cYbEI6+q242szXmg91uFyOOx5FEar rJ1A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=nutwB+ovVSTDlzGWQIq+7yCr9Sg+31F7/dz/czLhgcU=; b=QK4wKNeh/6HBumduhxIyo5PjyleR8QofDksMyhngqdWrMYDuKzngoyMqkHSDfouFrF AjIW8mfwdayRu/wYiD33mv+ZW5U3AA5t0+5D2zgyPo5EOA+vF2oTSYysZV8e5dOJNdHL mizstK66bugZbHrQDd2GiYxzw68FZeY1HMLLHZsl2UukRMRQVW5r+1mXdX2XQOXvMpUn muKyWiyMQ4TNwqwwalNBWDR5qQ60WHncwJSO4CT8h6n7gYemtdxhZPOCOdSpady3DDQU 4V6UeinCmVn9MTyFZ53DOjqoM0Y2H7gVX52/KcbUlrivybMPu03Qk5N93WBvM8C/2WnR 1VUg== X-Gm-Message-State: AJIora9sq/knfuGqKJr1fw2dNK92V8yL5k4lP1O7wHXS7XL5aGFACqEt it19h15SeYY9LRc2i7l/y65FQsJ6wC2ATM1wf1I= X-Google-Smtp-Source: AGRyM1sRqA9E6Sihax/qEyTEFdcUL0LwimkaORM9K540nWPJFeauZKXctNdRL2XhaIvsABBThkivgh9KLodVryaFqeY= X-Received: by 2002:a05:6a00:114e:b0:4c8:55f7:faad with SMTP id b14-20020a056a00114e00b004c855f7faadmr42797448pfm.86.1656016945036; Thu, 23 Jun 2022 13:42:25 -0700 (PDT) In-Reply-To: <922957d6545149287a6aec7b9d258bf2dd7603ef.camel@telenet.be> Received-SPF: pass client-ip=2607:f8b0:4864:20::533; envelope-from=aconchillo@gmail.com; helo=mail-pg1-x533.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FROM=0.001, HTML_MESSAGE=0.001, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: guile-devel@gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: "Developers list for Guile, the GNU extensibility library" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guile-devel-bounces+guile-devel=m.gmane-mx.org@gnu.org Original-Sender: "guile-devel" Xref: news.gmane.io gmane.lisp.guile.devel:21229 Archived-At: --000000000000c041cc05e2237d7e Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable On Thu, Jun 23, 2022 at 1:40 PM Maxime Devos wrote= : > Aleix Conchillo Flaqu=C3=A9 schreef op do 23-06-2022 om 13:27 [-0700]: > > + (put-string port (string-titlecase (symbol->string scheme))) > > I'd add a little explanation in a comment (e.g.: > > ;; While according to RFC 7617 Schemes are case-insensitive: > ;; > ;; =E2=80=98Note that both scheme and parameter names are matched > ;; case-insensitive=E2=80=99 > ;; > ;; some software (*) incorrectly assumes title case for scheme > ;; names, so use the more titlecase. > ;; > ;; (*): See, e.g., > ;; > ;; > > I think it's reasonable to do some changes in Guile to work-around > potential bugs in other software that Guile has no control over or even > knows about, at the same time Guile seems to be just following the > spec, the compatibility bug seems to be in the other software, so to > help the other software a bit, I think it would be best to report > things in the buggy software too. > > > I think you are right. The spec says clearly that it should be case insensitive. So, disregard this patch. Aleix --000000000000c041cc05e2237d7e Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable


On Thu, Jun 23, 2022 at 1:40= PM Maxime Devos <maximedevos@= telenet.be> wrote:
Aleix Conchillo Flaqu=C3=A9 schreef op do 23-06-2022 om 13:27 [-= 0700]:
> +=C2=A0=C2=A0=C2=A0=C2=A0 (put-string port (string-titlecase (symbol-&= gt;string scheme)))

I'd add a little explanation in a comment (e.g.:

=C2=A0 =C2=A0;; While according to RFC 7617 Schemes are case-insensitive: =C2=A0 =C2=A0;;
=C2=A0 =C2=A0;; =E2=80=98Note that both scheme and parameter names are matc= hed
=C2=A0 =C2=A0;; case-insensitive=E2=80=99
=C2=A0 =C2=A0;;
=C2=A0 =C2=A0;; some software (*) incorrectly assumes title case for scheme=
=C2=A0 =C2=A0;; names, so use the more titlecase.
=C2=A0 =C2=A0;;
=C2=A0 =C2=A0;; (*): See, e.g.,
=C2=A0 =C2=A0;; <https://[bug report 1]/>
=C2=A0 =C2=A0;; <https://[bug report 2]/>

I think it's reasonable to do some changes in Guile to work-around
potential bugs in other software that Guile has no control over or even
knows about, at the same time Guile seems to be just following the
spec, the compatibility bug seems to be in the other software, so to
help the other software a bit, I think it would be best to report
things in the buggy software too.



I think you are right. The spec says cle= arly that it should be case insensitive.

So, disregard= this patch.

Aleix
--000000000000c041cc05e2237d7e--