guile-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH] web: send capitalized authorization header scheme


From: Aleix Conchillo Flaqué
Subject: Re: [PATCH] web: send capitalized authorization header scheme
Date: Fri, 24 Jun 2022 09:35:43 -0700


On Fri, Jun 24, 2022 at 9:28 AM Maxime Devos <maximedevos@telenet.be> wrote:
Aleix Conchillo Flaqué schreef op vr 24-06-2022 om 09:05 [-0700]:
> * module/web/http.scm (write-credentials): capitalize authorization
> header scheme. The standard allows the scheme to be case-insensitive,
> however most libraries out there expect the scheme to be capitalized,
> which is what it is actually used in RFC
> docs (e.g. https://datatracker.ietf.org/doc/html/rfc7617#section-2). Some
> libraries even reject lowercase scheme making Guile incompatible.

This comment looks more useful to me to put in the source code, to help
future readers of the source code, otherwise they would have to dig
through the git history.  As mentioned previously, this could be
something like:

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

which would also address the issue of not forgetting that Guile's old
behaviour is correct, it's the other party that's not following the
specification.


This makes sense. I left the comment in the commit log as well. Sent again.

Thank you!

Aleix

reply via email to

[Prev in Thread] Current Thread [Next in Thread]