Bug 248219

Summary: ARQL truncates canonicalWebPageURL when it contains encoded query parameters
Product: WebKit Reporter: Miles <mail>
Component: New BugsAssignee: Nobody <webkit-unassigned>
Status: NEW ---    
Severity: Normal CC: ahmad.saleem792, annevk, dino, webkit-bug-importer
Priority: P2 Keywords: InRadar
Version: Safari 16   
Hardware: iPhone / iPad   
OS: iOS 17   

Description Miles 2022-11-22 05:58:17 PST
When passing canonicalWebPageURL to ARQL as part of the USDZ file path, if the canonicalWebPageURL contains query parameters as part of the URL, even when URI encoded, ARQL will truncate the shared URL down to (and including) the first occurrence of an encoded '&' when clicking on the Share button from within the ARQL session.

For example, when giving a USDZ a path of:

https://example.com/example.usdz#canonicalWebPageURL=https%3A%2F%2Fexample.com%2F%3Ffoo%3D111%26bar%3D222

The shared URL will get truncated down to:

https://example.com/?foo=111

Rather than:

https://example.com/?foo=111&bar=222

This makes it not possible to specify a canonicalWebPageURL containing multiple query string parameters.

Repro:

- Visit: https://usdz-params.glitch.me
- Scroll to "6. Complex Share URL".
- Tap the image to launch ARQL.
- Model opens in ARQL.
- Tap the Share button. 
- Copy the shared URL.
- Observe the shared URL is truncated.
Comment 1 Radar WebKit Bug Importer 2022-11-29 05:59:16 PST
<rdar://problem/102762712>
Comment 2 Miles 2023-03-16 04:28:28 PDT
Still seeing this as an issue in iOS 16.4 Public Beta 4.
Comment 3 Miles 2023-04-10 11:20:07 PDT
Still seeing this as an issue in iOS 16.5 public beta
Comment 4 Miles 2023-07-12 01:54:29 PDT
Still an issue in iOS 17.0 Beta 3.
Comment 5 Miles 2023-08-10 11:23:00 PDT
Still an issue in iOS 17.0 Dev Beta 5
Comment 6 Miles 2023-10-30 04:18:37 PDT
This is still an issue in iOS 17.2 beta (21C5029g)

Any chance of getting a fix in sometime?
Comment 7 Miles 2023-11-16 03:53:28 PST
Still an issue in iOS 17.2 beta 3 (21C5046c)
Comment 8 Miles 2023-12-12 15:18:02 PST
Still an issue in iOS 17.3 beta (21D5026f)
Comment 9 Miles 2024-02-11 13:46:37 PST
Still an issue in iOS 17.4 beta (21E5195e)
Comment 10 Miles 2024-02-11 13:58:18 PST
At this point, with this bug being present for over a year, we have found ways to work around it. For websites / web apps that may require sharing of 3D experiences that would have been otherwise been configured through URL query parameters, instead we have implement URL shortening rules and pass that as the canonicalWebPageURL ARQL parameter.
Comment 11 Miles 2024-04-08 06:12:46 PDT
Still an issue in iOS 17.5 beta.