Repository navigation
Conversation
addressable 2.10.0 validates the host component and rejects a colon outside an IP literal. DockerURIConverter passed "host:port" as host:, so converting any image reference with a registry port raised Addressable::URI::InvalidURIError, which fails the host:port examples in docker_uri_converter_spec.rb (and the dependabot bump in cloudfoundry#5710). Pass the value as authority: instead, which accepts host[:port] and yields the same output on 2.9.2 and 2.10.0. Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Samze
marked this pull request as ready for review
December 2, 2026 20:36
Passing the registry as `authority:` changes behaviour for inputs the existing examples do not exercise. Pin the current behaviour for IPv6 literals, zero and zero-padded ports, non-numeric and empty ports, and userinfo. Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
addressable2.9.2 → 2.10.0 in the rootGemfile.lock.DockerURIConverterso it works with 2.10.0.2.10.0 includes fixes for a batch of advisories published on 2026-12-01/02 (e.g. GHSA-qrq6-rcpx-pmm6, GHSA-mrrj-5mhw-rcf2, GHSA-xj9m-f88p-5j38, GHSA-xfg6-27c4-wr4r); all list 2.10.0 as the first patched version.
Why the code change is needed
UriUtils.parse_docker_urireturns the registry host together with its port (e.g.10.244.2.6:8080).DockerURIConverterpassed that ashost:toAddressable::URI.new. 2.10.0 now rejects a colon in a host unless it is inside an IP literal:This is what fails the five
host:portexamples indocker_uri_converter_spec.rb, and it is why the dependabot bump in #5710 is red.Passing the value as
authority:instead acceptshost[:port]and gives identical output on 2.9.2 and 2.10.0 for valid image references (checked for10.244.2.6:8080,foobar:8080,localhost,docker.io,[::1]:5000).Malformed registry parts are handled differently by
authority:than byhost:(same on 2.9.2 and 2.10.0):example.com:abc/imageandexample.com:/imagenow raiseAddressable::URI::InvalidURIError(invalid port);host:serialized them as-is.example.com:0/imagedrops the port andexample.com:05000/imagebecomes:5000.user:pass@example.com/imagenow serializes with the userinfo;host:raisedInvalidURIError.Valid references are unaffected. Such malformed references were already rejected downstream (BBS URL validation).
Testing
docker_uri_converter_spec.rbexamples for the cases whereauthority:differs fromhost:: IPv6 with port,:0,:05000, non-numeric and empty ports, and userinfo.docker_uri_converter_spec.rbfails 5/16 without the change and passes 16/16 with it. I ran this on a downstream fork whose converter and spec are byte-identical to this repo's, not in this repo, so please rely on CI here.Notes
docs/v3lockfile (build(deps): bump addressable from 2.9.1 to 2.10.0 in /docs/v3 #5739) is separate and not touched.🤖 Generated with Claude Code