<?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>220019</bug_id>
          
          <creation_ts>2020-12-18 10:43:57 -0800</creation_ts>
          <short_desc>Login flows on sites with ITP quirks no longer work with ITP disabled</short_desc>
          <delta_ts>2020-12-18 16:12:08 -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>WebKit Misc.</component>
          <version>WebKit Nightly Build</version>
          <rep_platform>Unspecified</rep_platform>
          <op_sys>Unspecified</op_sys>
          <bug_status>RESOLVED</bug_status>
          <resolution>FIXED</resolution>
          
          
          <bug_file_loc></bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords>InRadar</keywords>
          <priority>P2</priority>
          <bug_severity>Normal</bug_severity>
          <target_milestone>---</target_milestone>
          
          
          <everconfirmed>1</everconfirmed>
          <reporter name="Kate Cheney">katherine_cheney</reporter>
          <assigned_to name="Kate Cheney">katherine_cheney</assigned_to>
          <cc>achristensen</cc>
    
    <cc>bfulgham</cc>
    
    <cc>darin</cc>
    
    <cc>webkit-bug-importer</cc>
    
    <cc>wilander</cc>
          

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>1715750</commentid>
    <comment_count>0</comment_count>
    <who name="Kate Cheney">katherine_cheney</who>
    <bug_when>2020-12-18 10:43:57 -0800</bug_when>
    <thetext>We should add a check for ITP enabled before attempting to apply quirks, otherwise the quirks will commandeer the login process, fail (because no ITP), and thus result in inability to login when ITP is disabled.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1715751</commentid>
    <comment_count>1</comment_count>
    <who name="Radar WebKit Bug Importer">webkit-bug-importer</who>
    <bug_when>2020-12-18 10:44:51 -0800</bug_when>
    <thetext>&lt;rdar://problem/72472858&gt;</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1715752</commentid>
    <comment_count>2</comment_count>
      <attachid>416529</attachid>
    <who name="Kate Cheney">katherine_cheney</who>
    <bug_when>2020-12-18 10:50:09 -0800</bug_when>
    <thetext>Created attachment 416529
Patch</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1715757</commentid>
    <comment_count>3</comment_count>
      <attachid>416529</attachid>
    <who name="Darin Adler">darin</who>
    <bug_when>2020-12-18 10:59:23 -0800</bug_when>
    <thetext>Comment on attachment 416529
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=416529&amp;action=review

&gt; Source/WebCore/ChangeLog:14
&gt; +        No new tests, this will fix login flows on sites with ITP quirks when
&gt; +        ITP is turned off. I confirmed these cases manually.

Disappointing there’s no way to test this. A test has value even in a simple case like this, so if you do think of a way to validate it, that would be welcome.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1715818</commentid>
    <comment_count>4</comment_count>
    <who name="Kate Cheney">katherine_cheney</who>
    <bug_when>2020-12-18 14:54:05 -0800</bug_when>
    <thetext>(In reply to Darin Adler from comment #3)
&gt; Comment on attachment 416529 [details]
&gt; Patch

Thank you for the review!

&gt; 
&gt; View in context:
&gt; https://bugs.webkit.org/attachment.cgi?id=416529&amp;action=review
&gt; 
&gt; &gt; Source/WebCore/ChangeLog:14
&gt; &gt; +        No new tests, this will fix login flows on sites with ITP quirks when
&gt; &gt; +        ITP is turned off. I confirmed these cases manually.
&gt; 
&gt; Disappointing there’s no way to test this. A test has value even in a simple
&gt; case like this, so if you do think of a way to validate it, that would be
&gt; welcome.

I have been trying to think of a good way to test this. We’d need to test that we do not trigger the quirks when ITP is disabled. I don’t believe our test infrastructure supports loading arbitrary domains, so this eliminates testing an actual quirk’d site. 

One idea is I could add a new simple quirk in this function for localhost and then create a layout test for it to make sure that the quirk does not work with ITP disabled. But, I am not sure it is a good idea to add code in WebCore that is only triggered for a test case.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1715827</commentid>
    <comment_count>5</comment_count>
    <who name="Darin Adler">darin</who>
    <bug_when>2020-12-18 15:37:45 -0800</bug_when>
    <thetext>(In reply to katherine_cheney from comment #4)
&gt; I have been trying to think of a good way to test this. We’d need to test
&gt; that we do not trigger the quirks when ITP is disabled. I don’t believe our
&gt; test infrastructure supports loading arbitrary domains, so this eliminates
&gt; testing an actual quirk’d site. 

I think we should consider adding a way to &quot;spoof&quot; which site something is coming from in WebKitTestRunner, to test site-specific hacks. That could be used to make tests for bugs like this one, without requiring we add something specific to this quirk. Worth talking to some other WebKit people about how easy that would be.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1715843</commentid>
    <comment_count>6</comment_count>
    <who name="Kate Cheney">katherine_cheney</who>
    <bug_when>2020-12-18 16:08:08 -0800</bug_when>
    <thetext>(In reply to Darin Adler from comment #5)
&gt; (In reply to katherine_cheney from comment #4)
&gt; &gt; I have been trying to think of a good way to test this. We’d need to test
&gt; &gt; that we do not trigger the quirks when ITP is disabled. I don’t believe our
&gt; &gt; test infrastructure supports loading arbitrary domains, so this eliminates
&gt; &gt; testing an actual quirk’d site. 
&gt; 
&gt; I think we should consider adding a way to &quot;spoof&quot; which site something is
&gt; coming from in WebKitTestRunner, to test site-specific hacks. That could be
&gt; used to make tests for bugs like this one, without requiring we add
&gt; something specific to this quirk. Worth talking to some other WebKit people
&gt; about how easy that would be.

Ok, I like that idea. I filed rdar://72484249 and will talk with some others about the best way to do this.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1715848</commentid>
    <comment_count>7</comment_count>
    <who name="EWS">ews-feeder</who>
    <bug_when>2020-12-18 16:12:07 -0800</bug_when>
    <thetext>Committed r270995: &lt;https://trac.webkit.org/changeset/270995&gt;

All reviewed patches have been landed. Closing bug and clearing flags on attachment 416529.</thetext>
  </long_desc>
      
          <attachment
              isobsolete="0"
              ispatch="1"
              isprivate="0"
          >
            <attachid>416529</attachid>
            <date>2020-12-18 10:50:09 -0800</date>
            <delta_ts>2020-12-18 16:12:08 -0800</delta_ts>
            <desc>Patch</desc>
            <filename>bug-220019-20201218105008.patch</filename>
            <type>text/plain</type>
            <size>2158</size>
            <attacher name="Kate Cheney">katherine_cheney</attacher>
            
              <data encoding="base64">U3VidmVyc2lvbiBSZXZpc2lvbjogMjcwOTY4CmRpZmYgLS1naXQgYS9Tb3VyY2UvV2ViQ29yZS9D
aGFuZ2VMb2cgYi9Tb3VyY2UvV2ViQ29yZS9DaGFuZ2VMb2cKaW5kZXggNjY1MWMyZmQzOTg2OTJj
YWIyZDQ3YWM3ZDUzYTEzY2UxN2Y3MDZhYS4uZWFlNzgxZjliZDgxZTMzMTQ1ZWVmMGNiZTc1NzRk
NDA4MGQzNGQ5MyAxMDA2NDQKLS0tIGEvU291cmNlL1dlYkNvcmUvQ2hhbmdlTG9nCisrKyBiL1Nv
dXJjZS9XZWJDb3JlL0NoYW5nZUxvZwpAQCAtMSwzICsxLDIxIEBACisyMDIwLTEyLTE4ICBLYXRl
IENoZW5leSAgPGthdGhlcmluZV9jaGVuZXlAYXBwbGUuY29tPgorCisgICAgICAgIExvZ2luIGZs
b3dzIG9uIHNpdGVzIHdpdGggSVRQIHF1aXJrcyBubyBsb25nZXIgd29yayB3aXRoIElUUCBkaXNh
YmxlZAorICAgICAgICBodHRwczovL2J1Z3Mud2Via2l0Lm9yZy9zaG93X2J1Zy5jZ2k/aWQ9MjIw
MDE5CisgICAgICAgIDxyZGFyOi8vcHJvYmxlbS83MjQ3Mjg1OD4KKworICAgICAgICBSZXZpZXdl
ZCBieSBOT0JPRFkgKE9PUFMhKS4KKworICAgICAgICBXZSBzaG91bGQgYWRkIGEgY2hlY2sgZm9y
IElUUCBlbmFibGVkIGJlZm9yZSBhdHRlbXB0aW5nIHRvIGFwcGx5IHF1aXJrcywKKyAgICAgICAg
b3RoZXJ3aXNlIHRoZSBxdWlya3Mgd2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