<?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>182629</bug_id>
          
          <creation_ts>2018-02-08 15:49:09 -0800</creation_ts>
          <short_desc>[macOS, iOS] Expose OS marketing version in UserAgent</short_desc>
          <delta_ts>2019-08-21 09:29:25 -0700</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>1</classification_id>
          <classification>Unclassified</classification>
          <product>WebKit</product>
          <component>WebCore 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>
          
          <see_also>https://bugs.webkit.org/show_bug.cgi?id=200605</see_also>
    
    <see_also>https://bugs.webkit.org/show_bug.cgi?id=200948</see_also>
          <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>
          <dependson>180365</dependson>
          <blocked>192809</blocked>
          <everconfirmed>1</everconfirmed>
          <reporter name="Brent Fulgham">bfulgham</reporter>
          <assigned_to name="Brent Fulgham">bfulgham</assigned_to>
          <cc>bfulgham</cc>
    
    <cc>cdumez</cc>
    
    <cc>commit-queue</cc>
    
    <cc>dbates</cc>
    
    <cc>mitz</cc>
    
    <cc>mjs</cc>
    
    <cc>rniwa</cc>
    
    <cc>sam</cc>
    
    <cc>tonikitoo</cc>
    
    <cc>webkit-bug-importer</cc>
          

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>1397751</commentid>
    <comment_count>0</comment_count>
    <who name="Brent Fulgham">bfulgham</who>
    <bug_when>2018-02-08 15:49:09 -0800</bug_when>
    <thetext>Allow the UserAgent to expose the marketing version of the operating system WebKit is running on.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1397759</commentid>
    <comment_count>1</comment_count>
    <who name="Radar WebKit Bug Importer">webkit-bug-importer</who>
    <bug_when>2018-02-08 16:24:34 -0800</bug_when>
    <thetext>&lt;rdar://problem/37370975&gt;</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1397760</commentid>
    <comment_count>2</comment_count>
      <attachid>333434</attachid>
    <who name="Brent Fulgham">bfulgham</who>
    <bug_when>2018-02-08 16:25:35 -0800</bug_when>
    <thetext>Created attachment 333434
Patch</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1397761</commentid>
    <comment_count>3</comment_count>
    <who name="">mitz</who>
    <bug_when>2018-02-08 16:34:28 -0800</bug_when>
    <thetext>Having a variable user-agent string like this has been a constant source of website compatibility bugs.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1397768</commentid>
    <comment_count>4</comment_count>
    <who name="Brent Fulgham">bfulgham</who>
    <bug_when>2018-02-08 17:05:13 -0800</bug_when>
    <thetext>(In reply to mitz from comment #3)
&gt; Having a variable user-agent string like this has been a constant source of
&gt; website compatibility bugs.

That&apos;s true. But there are also compelling reasons why some level of variation is needed by websites.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1397770</commentid>
    <comment_count>5</comment_count>
    <who name="Sam Weinig">sam</who>
    <bug_when>2018-02-08 17:08:11 -0800</bug_when>
    <thetext>(In reply to Brent Fulgham from comment #4)
&gt; (In reply to mitz from comment #3)
&gt; &gt; Having a variable user-agent string like this has been a constant source of
&gt; &gt; website compatibility bugs.
&gt; 
&gt; That&apos;s true. But there are also compelling reasons why some level of
&gt; variation is needed by websites.

What are those reasons?</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1397957</commentid>
    <comment_count>6</comment_count>
    <who name="Brent Fulgham">bfulgham</who>
    <bug_when>2018-02-09 09:06:23 -0800</bug_when>
    <thetext>(In reply to Sam Weinig from comment #5)
&gt; (In reply to Brent Fulgham from comment #4)
&gt; &gt; (In reply to mitz from comment #3)
&gt; &gt; &gt; Having a variable user-agent string like this has been a constant source of
&gt; &gt; &gt; website compatibility bugs.
&gt; &gt; 
&gt; &gt; That&apos;s true. But there are also compelling reasons why some level of
&gt; &gt; variation is needed by websites.
&gt; 
&gt; What are those reasons?

The primary reasons were:

1. WebKit sometimes ships with bugs that can be worked around at the website level. Having a release version allows websites to activate workarounds where needed.

2. Decisions about what site content to send to a user agent are often made before the page is loaded. Having UA information when connecting to the server allows websites to send only the relevant payload (e.g., more recent javascript, more efficient image formats, etc.)

3. Safari (for example) ships with the same version on several operating system revisions. Sometimes bugs exist in specific OS revisions that websites can work around.

For these reasons, we decided to relax some of the restrictions we had originally planned on making.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1398010</commentid>
    <comment_count>7</comment_count>
      <attachid>333434</attachid>
    <who name="Daniel Bates">dbates</who>
    <bug_when>2018-02-09 10:44:46 -0800</bug_when>
    <thetext>Comment on attachment 333434
Patch

OK.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1398014</commentid>
    <comment_count>8</comment_count>
      <attachid>333434</attachid>
    <who name="Daniel Bates">dbates</who>
    <bug_when>2018-02-09 10:48:54 -0800</bug_when>
    <thetext>Comment on attachment 333434
Patch

As others have already brought up, this seems like it is moving us back a step and it is unclear how valuable the OS version is for a site to work around WebKit issues given that it does not seem to provide sufficient granularity. Sites that depend on such version information will keep their WebKit workarounds longer than may be necessary.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1398017</commentid>
    <comment_count>9</comment_count>
    <who name="Daniel Bates">dbates</who>
    <bug_when>2018-02-09 10:58:34 -0800</bug_when>
    <thetext>(In reply to Daniel Bates from comment #8)
&gt; Comment on attachment 333434 [details]
&gt; Patch
&gt; 
&gt; As others have already brought up, this seems like it is moving us back a
&gt; step and it is unclear how valuable the OS version is for a site to work
&gt; around WebKit issues given that it does not seem to provide sufficient
&gt; granularity.

Obviously, the remark about granularity is specific to Mac where we release Safari/WebKit updates out-of-band with OS updates. On iOS, a publicly released version of WebKit always implies a new rev of the OS; =&gt; the version information is more meaningful.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1398022</commentid>
    <comment_count>10</comment_count>
    <who name="">mitz</who>
    <bug_when>2018-02-09 11:04:25 -0800</bug_when>
    <thetext>(In reply to Brent Fulgham from comment #6)
&gt; (In reply to Sam Weinig from comment #5)
&gt; &gt; (In reply to Brent Fulgham from comment #4)
&gt; &gt; &gt; (In reply to mitz from comment #3)
&gt; &gt; &gt; &gt; Having a variable user-agent string like this has been a constant source of
&gt; &gt; &gt; &gt; website compatibility bugs.
&gt; &gt; &gt; 
&gt; &gt; &gt; That&apos;s true. But there are also compelling reasons why some level of
&gt; &gt; &gt; variation is needed by websites.
&gt; &gt; 
&gt; &gt; What are those reasons?
&gt; 
&gt; The primary reasons were:
&gt; 
&gt; 1. WebKit sometimes ships with bugs that can be worked around at the website
&gt; level. Having a release version allows websites to activate workarounds
&gt; where needed.

Shouldn’t WebKit provide a direct and explicit way for websites to determine that a bug is fixed?

&gt; 
&gt; 2. Decisions about what site content to send to a user agent are often made
&gt; before the page is loaded. Having UA information when connecting to the
&gt; server allows websites to send only the relevant payload (e.g., more recent
&gt; javascript, more efficient image formats, etc.)

Aren’t there other request headers dedicated to explicitly, directly conveying what the user agent supports?

&gt; 
&gt; 3. Safari (for example) ships with the same version on several operating
&gt; system revisions. Sometimes bugs exist in specific OS revisions that
&gt; websites can work around.

See 1.

&gt; 
&gt; For these reasons, we decided to relax some of the restrictions we had
&gt; originally planned on making.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1398031</commentid>
    <comment_count>11</comment_count>
      <attachid>333434</attachid>
    <who name="WebKit Commit Bot">commit-queue</who>
    <bug_when>2018-02-09 11:19:46 -0800</bug_when>
    <thetext>Comment on attachment 333434
Patch

Clearing flags on attachment: 333434

Committed r228334: &lt;https://trac.webkit.org/changeset/228334&gt;</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1398032</commentid>
    <comment_count>12</comment_count>
    <who name="WebKit Commit Bot">commit-queue</who>
    <bug_when>2018-02-09 11:19:47 -0800</bug_when>
    <thetext>All reviewed patches have been landed.  Closing bug.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1418491</commentid>
    <comment_count>13</comment_count>
    <who name="Brent Fulgham">bfulgham</who>
    <bug_when>2018-04-27 08:39:51 -0700</bug_when>
    <thetext>Note: For people arriving here looking for ways to live in a world with a frozen user agent, please look at &lt;https://developer.mozilla.org/en-US/docs/Learn/Tools_and_testing/Cross_browser_testing/Feature_detection&gt;</thetext>
  </long_desc>
      
          <attachment
              isobsolete="0"
              ispatch="1"
              isprivate="0"
          >
            <attachid>333434</attachid>
            <date>2018-02-08 16:25:35 -0800</date>
            <delta_ts>2018-02-09 11:19:46 -0800</delta_ts>
            <desc>Patch</desc>
            <filename>bug-182629-20180208162535.patch</filename>
            <type>text/plain</type>
            <size>1878</size>
            <attacher name="Brent Fulgham">bfulgham</attacher>
            
              <data encoding="base64">SW5kZXg6IFNvdXJjZS9XZWJDb3JlL0NoYW5nZUxvZwo9PT09PT09PT09PT09PT09PT09PT09PT09
PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09Ci0tLSBTb3VyY2UvV2Vi
Q29yZS9DaGFuZ2VMb2cJKHJldmlzaW9uIDIyODMwMCkKKysrIFNvdXJjZS9XZWJDb3JlL0NoYW5n
ZUxvZwkod29ya2luZyBjb3B5KQpAQCAtMSwzICsxLDE3IEBACisyMDE4LTAyLTA4ICBCcmVudCBG
dWxnaGFtICA8YmZ1bGdoYW1AYXBwbGUuY29tPgorCisgICAgICAgIFttYWNPUywgaU9TXSBFeHBv
c2UgT1MgbWFya2V0aW5nIHZlcnNpb24gaW4gVXNlckFnZW50CisgICAgICAgIGh0dHBzOi8vYnVn
cy53ZWJraXQub3JnL3Nob3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