<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<!DOCTYPE bugzilla SYSTEM "https://bugs.webkit.org/page.cgi?id=bugzilla.dtd">

<bugzilla version="5.0.4.1"
          urlbase="https://bugs.webkit.org/"
          
          maintainer="admin@webkit.org"
>

    <bug>
          <bug_id>274224</bug_id>
          
          <creation_ts>2024-05-15 12:58:55 -0700</creation_ts>
          <short_desc>REGRESSION (276904@main): Breaks https://www.tax.ny.gov/online/.</short_desc>
          <delta_ts>2025-02-04 09:06:11 -0800</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>1</classification_id>
          <classification>Unclassified</classification>
          <product>WebKit</product>
          <component>JavaScriptCore</component>
          <version>WebKit Nightly Build</version>
          <rep_platform>Unspecified</rep_platform>
          <op_sys>Unspecified</op_sys>
          <bug_status>RESOLVED</bug_status>
          <resolution>FIXED</resolution>
          
          <see_also>https://bugs.webkit.org/show_bug.cgi?id=271946</see_also>
    
    <see_also>https://bugs.webkit.org/show_bug.cgi?id=272082</see_also>
    
    <see_also>https://bugs.webkit.org/show_bug.cgi?id=274225</see_also>
          <bug_file_loc></bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords>BrowserCompat, InRadar</keywords>
          <priority>P2</priority>
          <bug_severity>Normal</bug_severity>
          <target_milestone>---</target_milestone>
          
          
          <everconfirmed>1</everconfirmed>
          <reporter name="Mark Lam">mark.lam</reporter>
          <assigned_to name="Yijia Huang">yijia_huang</assigned_to>
          <cc>karlcow</cc>
    
    <cc>webkit-bug-importer</cc>
          

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>2035602</commentid>
    <comment_count>0</comment_count>
    <who name="Mark Lam">mark.lam</who>
    <bug_when>2024-05-15 12:58:55 -0700</bug_when>
    <thetext>Steps to reproduce:
1. Navigate to https://www.tax.ny.gov/online/
2. Click Log in
3. Observe &quot;Network connection was lost&quot; error message or blank white page.

This reproduces in MiniBrowser with 276904@main or later.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2035603</commentid>
    <comment_count>1</comment_count>
    <who name="Mark Lam">mark.lam</who>
    <bug_when>2024-05-15 12:59:32 -0700</bug_when>
    <thetext>This is caused by https://bugs.webkit.org/show_bug.cgi?id=271946.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2035604</commentid>
    <comment_count>2</comment_count>
    <who name="Radar WebKit Bug Importer">webkit-bug-importer</who>
    <bug_when>2024-05-15 12:59:48 -0700</bug_when>
    <thetext>&lt;rdar://problem/128149232&gt;</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2035605</commentid>
    <comment_count>3</comment_count>
    <who name="Mark Lam">mark.lam</who>
    <bug_when>2024-05-15 13:04:50 -0700</bug_when>
    <thetext>We&apos;ll have to revert the following:

https://commits.webkit.org/276904@main
https://commits.webkit.org/277023@main</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2035627</commentid>
    <comment_count>4</comment_count>
    <who name="Mark Lam">mark.lam</who>
    <bug_when>2024-05-15 13:56:25 -0700</bug_when>
    <thetext>The previous changes were reverted in 278825@main. See https://bugs.webkit.org/show_bug.cgi?id=274225.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2035633</commentid>
    <comment_count>5</comment_count>
    <who name="Mark Lam">mark.lam</who>
    <bug_when>2024-05-15 14:01:47 -0700</bug_when>
    <thetext>Honestly, I&apos;m not sure if this is actually a bug in this PR.  From my debugging, if I make the getter not prepend &quot;get &quot; to its name, the issue stops reproducing.  Meanwhile, Chrome and Firefox all do not implement the spec in https://tc39.es/ecma262/#sec-function.prototype.tostring, and hence, do appear to hit this issue.  For example, on Firefox,
```
String(Object.getOwnPropertyDescriptor((function() { &quot;use strict&quot;; }).__proto__, &quot;caller&quot;).get)
```
... yields:
```
&quot;function caller() {
    [native code]
}&quot;
```

Maybe someone needs to tell https://www.tax.ny.gov/online to fix their site, or we need more consensus support from Chrome and Firefox in order to land this.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2037247</commentid>
    <comment_count>6</comment_count>
    <who name="Karl Dubost">karlcow</who>
    <bug_when>2024-05-22 22:39:48 -0700</bug_when>
    <thetext>Mark, 

I do not have login access to https://www.tax.ny.gov/online 
Could you identify which part of the code triggers the bug?


Testing with:
Safari Technology Preview  191           20619.1.6.3
Firefox Nightly            128.0a1       12824.5.19
Google Chrome Canary       127.0.6495.0  6495.0


So this:
String(Object.getOwnPropertyDescriptor((function() { &quot;use strict&quot;; }).__proto__, &quot;caller&quot;).get)


Safari returns
&quot;function caller() {
    [native code]
}&quot;


Firefox returns
&quot;function caller() {
    [native code]
}&quot;


Chrome returns
&apos;function () { [native code] }&apos;</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2046735</commentid>
    <comment_count>7</comment_count>
    <who name="Mark Lam">mark.lam</who>
    <bug_when>2024-07-17 08:31:49 -0700</bug_when>
    <thetext>(In reply to Karl Dubost from comment #6)
&gt; Mark, 
&gt; 
&gt; I do not have login access to https://www.tax.ny.gov/online 
&gt; Could you identify which part of the code triggers the bug?

I do not have login access to https://www.tax.ny.gov/online either, but login access is not required.

Before 276904@main, trying to login will get some activity on https://www.tax.ny.gov/online.

After 276904@main, trying to login gives you a &quot;blank white page&quot;.

The only change in 276904@main is to rename a getter function:

   function input() { ...

should be:
   function get input() { ...

This is in accordance to the ECMA262 spec.  However, after that change in 276904@main (which makes us spec compliant), https://www.tax.ny.gov/online starts showing the &quot;blank white page&quot; on login attempts.  What we need to find out here is why that website does not like the spec compliant behavior.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2046825</commentid>
    <comment_count>8</comment_count>
    <who name="Karl Dubost">karlcow</who>
    <bug_when>2024-07-17 15:17:01 -0700</bug_when>
    <thetext>Given that Firefox returns the same thing than Safari, I wonder if it fails in Firefox too. 

So on STP Release 198 (Safari 18.0, WebKit 20619.1.20.7)

1. Go to https://www.tax.ny.gov/online/
2. Click on Login button

Result:
The site opens a new tab with https://my.ny.gov/LoginV4/login.xhtml?APP=nyappdtf
No blank page at the end. (it just takes time 1s to 3s while the page is blank)

Same behavior and delay on 
* Chrome Canary Version 128.0.6598.0 (Official Build) canary (arm64)
* Firefox Nightly 128.0 (64 bits)
* Working also on a recent internal version of Safari

Mark, 
does it still happen for you? 
which version?</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2046872</commentid>
    <comment_count>9</comment_count>
    <who name="Karl Dubost">karlcow</who>
    <bug_when>2024-07-17 17:51:14 -0700</bug_when>
    <thetext>comment #8
So my bad, I had forgotten that the change had been reverted so it&apos;s normal this is working.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2046873</commentid>
    <comment_count>10</comment_count>
    <who name="Karl Dubost">karlcow</who>
    <bug_when>2024-07-17 17:51:23 -0700</bug_when>
    <thetext>comment #8
So my bad, I had forgotten that the change had been reverted so it&apos;s normal this is working.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2046947</commentid>
    <comment_count>11</comment_count>
    <who name="Karl Dubost">karlcow</who>
    <bug_when>2024-07-18 00:32:42 -0700</bug_when>
    <thetext>I&apos;m confused with this bug.

 Object.getOwnPropertyDescriptor(Document.prototype, &apos;title&apos;).get.toString()

Chrome: &apos;function get title() { [native code] }&apos;

Firefox:
&quot;function title() {
    [native code] 
}&quot;

Safari:
&quot;function title() {
    [native code]
}&quot;


In the current state. So Chrome does return the `get` 
and it is working with the https://www.tax.ny.gov/online/

Now, I also tested by setting Chrome with the UA string for Safari.
&apos;Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/605.1.15 (KHTML, like Gecko) Version/18.0 Safari/605.1.15&apos;
And this is still working.

if I set Safari with the Chrome UA
Then it fails.

So I suspect there is some user agent sniffing going on. 
which adjusts to the expected string, but I&apos;m not sure where in the code. 
That also means we can&apos;t fix it except by doing a Quirk.

Proposal: 
We re-land the code with set/get and a quirk in the same patch. 
which removes the set/get just for this site.

And we start an outreach effort to make them change.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2047091</commentid>
    <comment_count>12</comment_count>
    <who name="Yijia Huang">yijia_huang</who>
    <bug_when>2024-07-18 14:24:37 -0700</bug_when>
    <thetext>Pull request: https://github.com/WebKit/WebKit/pull/30980</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2047126</commentid>
    <comment_count>13</comment_count>
    <who name="Karl Dubost">karlcow</who>
    <bug_when>2024-07-18 18:34:28 -0700</bug_when>
    <thetext>We are also in the process of contacting them through radar 132049502
And hopefully we will not have to implement a Quirk.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2056611</commentid>
    <comment_count>14</comment_count>
    <who name="Yijia Huang">yijia_huang</who>
    <bug_when>2024-08-30 09:55:15 -0700</bug_when>
    <thetext>Pull request: https://github.com/WebKit/WebKit/pull/32950</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2089358</commentid>
    <comment_count>15</comment_count>
    <who name="Yijia Huang">yijia_huang</who>
    <bug_when>2025-01-23 14:51:42 -0800</bug_when>
    <thetext>Pull request: https://github.com/WebKit/WebKit/pull/39468</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2091832</commentid>
    <comment_count>16</comment_count>
    <who name="EWS">ews-feeder</who>
    <bug_when>2025-02-04 09:06:09 -0800</bug_when>
    <thetext>Committed 289786@main (e4a6a6964d55): &lt;https://commits.webkit.org/289786@main&gt;

Reviewed commits have been landed. Closing PR #39468 and removing active labels.</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>