Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

INTL_IDNA_VARIANT_UTS46 not defined having ICU < 4.6 #2448

Closed
ohader opened this issue Dec 10, 2019 · 10 comments
Closed

INTL_IDNA_VARIANT_UTS46 not defined having ICU < 4.6 #2448

ohader opened this issue Dec 10, 2019 · 10 comments
Milestone

Comments

@ohader
Copy link

ohader commented Dec 10, 2019

Guzzle version(s) affected: 6.5.0

Description
IDN conversion failed exception being thrown when dealing with domain name having regular ASCII characters (no IDN conversion required at all). Exception is thrown at https://github.com/guzzle/guzzle/blob/6.5.0/src/Client.php#L241

How to reproduce
Requires old version of ICU on e.g. PHP 7.2 (these two things are independent - unfortunately).

Possible Solution
Omit INTL_IDNA_VARIANT_UTS46 in case it's not available - at https://github.com/guzzle/guzzle/blob/6.5.0/src/Client.php#L221

Additional References

See the following references and how it was handled in the TYPO3 CMS project

@exotec
Copy link

exotec commented Dec 10, 2019

I also had problems with it this morning. Downgrade to 6.4.1 works

My ICU Version:
ICU version => 51.1
ICU Data version => 51.1
ICU TZData version => 2013b
ICU Unicode version => 6.2

Thanks to ohader who detected this problem!!!

@ohader
Copy link
Author

ohader commented Dec 10, 2019

ICU version => 51.1

I'm not entirely sure how ICU's versioning (http://site.icu-project.org/download) is supposed to work - referring to https://github.com/php/php-src/blob/PHP-7.2/ext/intl/idn/idn.c#L37 (same in current PHP 7.3 branch) they related to ICU 4.6

@exotec What was the exact PHP version (and vendor OS) you're using?

@exotec
Copy link

exotec commented Dec 10, 2019

PHP 7.2.10
Linux s1036 4.19.44-gentoo-mw1

@bramus
Copy link

bramus commented Dec 11, 2019

Problem was introduced with commit 9d47169#diff-ff73e042e738204c6da009e2ed19f783 (and shipped with 6.5.0)

Other libraries that use it include checks for its existence, falling back to INTL_IDNA_VARIANT_2003. See bcit-ci/CodeIgniter@4541bf9 for example.

Please release a hotfix. All CentOS 6 servers (on which many cPanel servers run) for example are stuck with ICU 4.2.1 and thus are affected by this.

@ohader
Copy link
Author

ohader commented Dec 11, 2019

Other libraries that use it include checks for its existence, falling back to INTL_IDNA_VARIANT_2003. See bcit-ci/CodeIgniter@4541bf9 for example.

Back then we had a similar idea, however on PHP 7.2 this leads to a corresponding deprecation message. That's why we kept the default variant if UTS46 is not available - see

@alexeyshockov
Copy link
Collaborator

alexeyshockov commented Dec 12, 2019

@ohader, @bramus, @exotec, please check #2454. Hope I didn't forget something.

reviewtypo3org pushed a commit to TYPO3/typo3 that referenced this issue Dec 13, 2019
Due to the INTL/ICU bug, which we
have seen on various places, Guzzle, which
does not cover our edge cases yet, ran
in the same issue as our Core versions earlier
in 2019.

See
guzzle/guzzle#2448
guzzle/guzzle#2454

For the time being, lets mark guzzle as
incompatible until Guzzle has solved the issue
and released a new version, so we can loosen
the conflict constraint.

Related: #87953
Resolves: #89904
Releases: master, 9.5, 8.7
Change-Id: If64fb9472d046f020c850cd0551beeaf78796b60
Reviewed-on: https://review.typo3.org/c/Packages/TYPO3.CMS/+/62606
Tested-by: TYPO3com <noreply@typo3.com>
Tested-by: Oliver Hader <oliver.hader@typo3.org>
Reviewed-by: Oliver Hader <oliver.hader@typo3.org>
TYPO3IncTeam pushed a commit to TYPO3-CMS/core that referenced this issue Dec 13, 2019
Due to the INTL/ICU bug, which we
have seen on various places, Guzzle, which
does not cover our edge cases yet, ran
in the same issue as our Core versions earlier
in 2019.

See
guzzle/guzzle#2448
guzzle/guzzle#2454

For the time being, lets mark guzzle as
incompatible until Guzzle has solved the issue
and released a new version, so we can loosen
the conflict constraint.

Related: #87953
Resolves: #89904
Releases: master, 9.5, 8.7
Change-Id: If64fb9472d046f020c850cd0551beeaf78796b60
Reviewed-on: https://review.typo3.org/c/Packages/TYPO3.CMS/+/62606
Tested-by: TYPO3com <noreply@typo3.com>
Tested-by: Oliver Hader <oliver.hader@typo3.org>
Reviewed-by: Oliver Hader <oliver.hader@typo3.org>
reviewtypo3org pushed a commit to TYPO3/typo3 that referenced this issue Dec 13, 2019
Due to the INTL/ICU bug, which we
have seen on various places, Guzzle, which
does not cover our edge cases yet, ran
in the same issue as our Core versions earlier
in 2019.

See
guzzle/guzzle#2448
guzzle/guzzle#2454

For the time being, lets mark guzzle as
incompatible until Guzzle has solved the issue
and released a new version, so we can loosen
the conflict constraint.

Related: #87953
Resolves: #89904
Releases: master, 9.5, 8.7
Change-Id: If64fb9472d046f020c850cd0551beeaf78796b60
Reviewed-on: https://review.typo3.org/c/Packages/TYPO3.CMS/+/62613
Tested-by: TYPO3com <noreply@typo3.com>
Tested-by: Oliver Hader <oliver.hader@typo3.org>
Reviewed-by: Oliver Hader <oliver.hader@typo3.org>
reviewtypo3org pushed a commit to TYPO3/typo3 that referenced this issue Dec 13, 2019
Due to the INTL/ICU bug, which we
have seen on various places, Guzzle, which
does not cover our edge cases yet, ran
in the same issue as our Core versions earlier
in 2019.

See
guzzle/guzzle#2448
guzzle/guzzle#2454

For the time being, lets mark guzzle as
incompatible until Guzzle has solved the issue
and released a new version, so we can loosen
the conflict constraint.

Related: #87953
Resolves: #89904
Releases: master, 9.5, 8.7
Change-Id: If64fb9472d046f020c850cd0551beeaf78796b60
Reviewed-on: https://review.typo3.org/c/Packages/TYPO3.CMS/+/62612
Tested-by: TYPO3com <noreply@typo3.com>
Tested-by: Oliver Hader <oliver.hader@typo3.org>
Reviewed-by: Oliver Hader <oliver.hader@typo3.org>
TYPO3IncTeam pushed a commit to TYPO3-CMS/core that referenced this issue Dec 13, 2019
Due to the INTL/ICU bug, which we
have seen on various places, Guzzle, which
does not cover our edge cases yet, ran
in the same issue as our Core versions earlier
in 2019.

See
guzzle/guzzle#2448
guzzle/guzzle#2454

For the time being, lets mark guzzle as
incompatible until Guzzle has solved the issue
and released a new version, so we can loosen
the conflict constraint.

Related: #87953
Resolves: #89904
Releases: master, 9.5, 8.7
Change-Id: If64fb9472d046f020c850cd0551beeaf78796b60
Reviewed-on: https://review.typo3.org/c/Packages/TYPO3.CMS/+/62613
Tested-by: TYPO3com <noreply@typo3.com>
Tested-by: Oliver Hader <oliver.hader@typo3.org>
Reviewed-by: Oliver Hader <oliver.hader@typo3.org>
TYPO3IncTeam pushed a commit to TYPO3-CMS/core that referenced this issue Dec 13, 2019
Due to the INTL/ICU bug, which we
have seen on various places, Guzzle, which
does not cover our edge cases yet, ran
in the same issue as our Core versions earlier
in 2019.

See
guzzle/guzzle#2448
guzzle/guzzle#2454

For the time being, lets mark guzzle as
incompatible until Guzzle has solved the issue
and released a new version, so we can loosen
the conflict constraint.

Related: #87953
Resolves: #89904
Releases: master, 9.5, 8.7
Change-Id: If64fb9472d046f020c850cd0551beeaf78796b60
Reviewed-on: https://review.typo3.org/c/Packages/TYPO3.CMS/+/62612
Tested-by: TYPO3com <noreply@typo3.com>
Tested-by: Oliver Hader <oliver.hader@typo3.org>
Reviewed-by: Oliver Hader <oliver.hader@typo3.org>
@jonnott
Copy link
Contributor

jonnott commented Dec 14, 2019

+1 for a fix .. I have CentOS 6 with ICU 4.2.1

@sagikazarmark sagikazarmark added this to the 6.5.1 milestone Dec 14, 2019
@imajinyun
Copy link

Skip version 6.5.0 and you're ready to go

composer require guzzlehttp/guzzle:'>=6.3.0 <6.5.0 || ^6.5.1'

@Nyholm
Copy link
Member

Nyholm commented Dec 21, 2019

This is fixed by #2454

Will be released in 6.5.1. (hopefully today)

@Nyholm Nyholm closed this as completed Dec 21, 2019
reviewtypo3org pushed a commit to TYPO3/typo3 that referenced this issue Mar 6, 2020
Guzzle 6.5.0 introduced an issue with umlaut domains
which was fixed in Guzzle 6.5.1 and Guzzle 6.5.2
respectively.

The conflict section in composer.json is now
updated, in order to allow composer-based TYPO3
installations to
a) allow TYPO3 updates to 10.3.x/9.5.14/8.7.31 even
if guzzle has been locked in composer.lock to 6.5.2 already
b) allow to use the latest Guzzle fixes again

Used composer command:
  composer update --lock

See guzzle/guzzle#2448 which
was integrated in Guzzle 6.5.1 (which was released AFTER
our core release in December 2019)

Resolves: #90634
Releases: master, 9.5, 8.7
Change-Id: If6c2f3ef6529109148569f1af9472b0bcb44c9b9
Reviewed-on: https://review.typo3.org/c/Packages/TYPO3.CMS/+/63548
Reviewed-by: Andreas Fernandez <a.fernandez@scripting-base.de>
Reviewed-by: Benni Mack <benni@typo3.org>
Tested-by: TYPO3com <noreply@typo3.com>
Tested-by: Benni Mack <benni@typo3.org>
TYPO3IncTeam pushed a commit to TYPO3-CMS/core that referenced this issue Mar 6, 2020
Guzzle 6.5.0 introduced an issue with umlaut domains
which was fixed in Guzzle 6.5.1 and Guzzle 6.5.2
respectively.

The conflict section in composer.json is now
updated, in order to allow composer-based TYPO3
installations to
a) allow TYPO3 updates to 10.3.x/9.5.14/8.7.31 even
if guzzle has been locked in composer.lock to 6.5.2 already
b) allow to use the latest Guzzle fixes again

Used composer command:
  composer update --lock

See guzzle/guzzle#2448 which
was integrated in Guzzle 6.5.1 (which was released AFTER
our core release in December 2019)

Resolves: #90634
Releases: master, 9.5, 8.7
Change-Id: If6c2f3ef6529109148569f1af9472b0bcb44c9b9
Reviewed-on: https://review.typo3.org/c/Packages/TYPO3.CMS/+/63548
Reviewed-by: Andreas Fernandez <a.fernandez@scripting-base.de>
Reviewed-by: Benni Mack <benni@typo3.org>
Tested-by: TYPO3com <noreply@typo3.com>
Tested-by: Benni Mack <benni@typo3.org>
reviewtypo3org pushed a commit to TYPO3/typo3 that referenced this issue Mar 6, 2020
Guzzle 6.5.0 introduced an issue with umlaut domains
which was fixed in Guzzle 6.5.1 and Guzzle 6.5.2
respectively.

The conflict section in composer.json is now
updated, in order to allow composer-based TYPO3
installations to
a) allow TYPO3 updates to 10.3.x/9.5.14/8.7.31 even
if guzzle has been locked in composer.lock to 6.5.2 already
b) allow to use the latest Guzzle fixes again

Used composer command:
  composer update --lock

See guzzle/guzzle#2448 which
was integrated in Guzzle 6.5.1 (which was released AFTER
our core release in December 2019)

Resolves: #90634
Releases: master, 9.5, 8.7
Change-Id: If6c2f3ef6529109148569f1af9472b0bcb44c9b9
Reviewed-on: https://review.typo3.org/c/Packages/TYPO3.CMS/+/63470
Tested-by: TYPO3com <noreply@typo3.com>
Tested-by: Benni Mack <benni@typo3.org>
Reviewed-by: Benni Mack <benni@typo3.org>
reviewtypo3org pushed a commit to TYPO3/typo3 that referenced this issue Mar 6, 2020
Guzzle 6.5.0 introduced an issue with umlaut domains
which was fixed in Guzzle 6.5.1 and Guzzle 6.5.2
respectively.

The conflict section in composer.json is now
updated, in order to allow composer-based TYPO3
installations to
a) allow TYPO3 updates to 10.3.x/9.5.14/8.7.31 even
if guzzle has been locked in composer.lock to 6.5.2 already
b) allow to use the latest Guzzle fixes again

Used composer command:
  composer update --lock

See guzzle/guzzle#2448 which
was integrated in Guzzle 6.5.1 (which was released AFTER
our core release in December 2019)

Resolves: #90634
Releases: master, 9.5, 8.7
Change-Id: If6c2f3ef6529109148569f1af9472b0bcb44c9b9
Reviewed-on: https://review.typo3.org/c/Packages/TYPO3.CMS/+/63560
Tested-by: TYPO3com <noreply@typo3.com>
Tested-by: Benni Mack <benni@typo3.org>
Reviewed-by: Benni Mack <benni@typo3.org>
TYPO3IncTeam pushed a commit to TYPO3-CMS/core that referenced this issue Mar 6, 2020
Guzzle 6.5.0 introduced an issue with umlaut domains
which was fixed in Guzzle 6.5.1 and Guzzle 6.5.2
respectively.

The conflict section in composer.json is now
updated, in order to allow composer-based TYPO3
installations to
a) allow TYPO3 updates to 10.3.x/9.5.14/8.7.31 even
if guzzle has been locked in composer.lock to 6.5.2 already
b) allow to use the latest Guzzle fixes again

Used composer command:
  composer update --lock

See guzzle/guzzle#2448 which
was integrated in Guzzle 6.5.1 (which was released AFTER
our core release in December 2019)

Resolves: #90634
Releases: master, 9.5, 8.7
Change-Id: If6c2f3ef6529109148569f1af9472b0bcb44c9b9
Reviewed-on: https://review.typo3.org/c/Packages/TYPO3.CMS/+/63470
Tested-by: TYPO3com <noreply@typo3.com>
Tested-by: Benni Mack <benni@typo3.org>
Reviewed-by: Benni Mack <benni@typo3.org>
TYPO3IncTeam pushed a commit to TYPO3-CMS/core that referenced this issue Mar 6, 2020
Guzzle 6.5.0 introduced an issue with umlaut domains
which was fixed in Guzzle 6.5.1 and Guzzle 6.5.2
respectively.

The conflict section in composer.json is now
updated, in order to allow composer-based TYPO3
installations to
a) allow TYPO3 updates to 10.3.x/9.5.14/8.7.31 even
if guzzle has been locked in composer.lock to 6.5.2 already
b) allow to use the latest Guzzle fixes again

Used composer command:
  composer update --lock

See guzzle/guzzle#2448 which
was integrated in Guzzle 6.5.1 (which was released AFTER
our core release in December 2019)

Resolves: #90634
Releases: master, 9.5, 8.7
Change-Id: If6c2f3ef6529109148569f1af9472b0bcb44c9b9
Reviewed-on: https://review.typo3.org/c/Packages/TYPO3.CMS/+/63560
Tested-by: TYPO3com <noreply@typo3.com>
Tested-by: Benni Mack <benni@typo3.org>
Reviewed-by: Benni Mack <benni@typo3.org>
@jdmendez
Copy link

I might not understand the problem with this issue. I used the composer solution and it added a bunch of weird new scripts that I way too unnecessary. I solve the issue by commenting out the line 1153 where the constant is used, and defined the variant as null. That solved my problem without increasing risk with new scripts.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

10 participants