aboutsummaryrefslogtreecommitdiff
path: root/src/encoding
diff options
context:
space:
mode:
authorFábio Mata <fabio.mata@tecnico.ulisboa.pt>2024-03-19 22:58:26 +0000
committerDamien Neil <dneil@google.com>2024-05-22 22:52:38 +0000
commitcf06b1f1db9bf84301aa7e760267fdab46373116 (patch)
treed76068b5b7661f31138040cef4f1336a4986bfef /src/encoding
parenta8eaf56fe1412b1bb8f9d192fe806afd39d4b657 (diff)
downloadgo-cf06b1f1db9bf84301aa7e760267fdab46373116.tar.xz
net/url: fix missing handling for opaque value in ResolveReference method
The current implementation doesn't resolve as per spec RFC 3986 the case where the base URL has an opaque value, and the reference doesn't have either a scheme, authority or path. Currently, this specific case falls back to the "abs_path" or "rel_path" cases, where the final path results of the base_path being resolved relatively to the reference's, but since the opaque value is stored independently, it needs a case of its own. The algorith for resolving references is defined in RFC 3986 section 5.2.2: https://www.rfc-editor.org/rfc/rfc3986.html#section-5.2.2 Fixes #66084 Change-Id: I82813e2333d8f2c4433c742f10e8c941888b55ac GitHub-Last-Rev: cb96626988f4bd4546ee840ba50e2b4efa1e23f1 GitHub-Pull-Request: golang/go#66415 Reviewed-on: https://go-review.googlesource.com/c/go/+/572915 LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com> Reviewed-by: Damien Neil <dneil@google.com> Reviewed-by: Carlos Amedee <carlos@golang.org>
Diffstat (limited to 'src/encoding')
0 files changed, 0 insertions, 0 deletions