You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tomcat.apache.org by bu...@apache.org on 2022/07/21 20:04:23 UTC

[Bug 66175] New: Consider changing BasicAuthenticator to default to charset="UTF"

https://bz.apache.org/bugzilla/show_bug.cgi?id=66175

            Bug ID: 66175
           Summary: Consider changing BasicAuthenticator to default to
                    charset="UTF"
           Product: Tomcat 10
           Version: 10.1.0-M17
          Hardware: PC
            Status: NEW
          Severity: enhancement
          Priority: P2
         Component: Catalina
          Assignee: dev@tomcat.apache.org
          Reporter: knst.kolinko@gmail.com
  Target Milestone: ------

A support for using UTF-8 with BasicAuthenticator has already been implemented
since Tomcat 9.0.0 (in September 2017) - Bug 61280.

I think we may consider to change the default in BasicAuthenticator to be UTF-8
nowadays, for Tomcat 10.1 onwards.


Testing with Firefox 102 (see my comment in bug 66174), it does accept the
charset=UTF-8 parameter in the value of a WWW-Authenticate response header.

Moreover, regardless of whether such charset parameter was present is a
response header, Firefox encodes the credentials of a subsequent request with
UTF-8. The BasicAuthenticator by default expects ISO-8859-1 and cannot decode
them. - Tested with Apache Tomcat 9.0.65 and the manager web application.

See also: Bug 66174
https://cwiki.apache.org/confluence/display/TOMCAT/Character+Encoding#CharacterEncoding-Q10

-- 
You are receiving this mail because:
You are the assignee for the bug.
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org


[Bug 66175] Consider changing BasicAuthenticator to default to charset="UTF-8"

Posted by bu...@apache.org.
https://bz.apache.org/bugzilla/show_bug.cgi?id=66175

Michael Osipov <mi...@apache.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
            Summary|Consider changing           |Consider changing
                   |BasicAuthenticator to       |BasicAuthenticator to
                   |default to charset="UTF"    |default to charset="UTF-8"

-- 
You are receiving this mail because:
You are the assignee for the bug.
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org


[Bug 66175] Consider changing BasicAuthenticator to default to charset="UTF"

Posted by bu...@apache.org.
https://bz.apache.org/bugzilla/show_bug.cgi?id=66175

Mark Thomas <ma...@apache.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
         Resolution|---                         |FIXED

--- Comment #2 from Mark Thomas <ma...@apache.org> ---
Fixed in 11.0.x for 11.0.0-M1 onwards

-- 
You are receiving this mail because:
You are the assignee for the bug.
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org


[Bug 66175] Consider changing BasicAuthenticator to default to charset="UTF"

Posted by bu...@apache.org.
https://bz.apache.org/bugzilla/show_bug.cgi?id=66175

Christopher Schultz <ch...@christopherschultz.net> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 OS|                            |All

--- Comment #1 from Christopher Schultz <ch...@christopherschultz.net> ---
With our recent changes to switch everything to default to UTF-8, I think this
makes sense. I'm not sure which version of Tomcat first switched all the
defaults. 10? Or was it back to 9? I'm fairly sure 8.5 still has ISO-8859-1 as
default for everything to match the HTTP specs.

-- 
You are receiving this mail because:
You are the assignee for the bug.
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org