Bug 212937 - User-Agent on iPadOS is macOS
Summary: User-Agent on iPadOS is macOS
Status: RESOLVED INVALID
Alias: None
Product: WebKit
Classification: Unclassified
Component: WebKit API (show other bugs)
Version: Safari 13
Hardware: iPhone / iPad iOS 13
: P2 Major
Assignee: Nobody
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2020-06-08 16:13 PDT by goehdavi
Modified: 2020-07-23 21:34 PDT (History)
2 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description goehdavi 2020-06-08 16:13:11 PDT
It appears that by default on iPadOS, Safari requests sites as desktop (macOS). Is there a way so that we can still reliably differentiate iPadOS from macOS?
Comment 1 Alexey Proskuryakov 2020-06-08 17:09:15 PDT
This is expected behavior: https://webkit.org/blog/9674/new-webkit-features-in-safari-13/

Please do not implement any "Mac" vs. "iPad" code paths, and use feature detection for each specific that your website or application needs. You are welcome to reach out for assistance via email or slack, <https://webkit.org/getting-started/#staying-in-touch>
Comment 2 goehdavi 2020-07-23 14:00:43 PDT
We use the device type and OS in logs and metrics. It's very useful for us to have this information.
Comment 3 goehdavi 2020-07-23 14:01:22 PDT
See above comment.
Comment 4 Brady Eidson 2020-07-23 21:34:06 PDT
(In reply to goehdavi from comment #2)
> We use the device type and OS in logs and metrics. It's very useful for us
> to have this information.

We understand that.

The UA string is misused for feature detection, and variance in the UA string is a huge fingerprinting vector.

Both WebKit and Safari will be locking down UA strings more going forward, not less.

We're happy to keep having the discussion with regards to the defaults in the WebKit open source project, but Apple's decision to share UA's on iPadOS and macOS is a vendor decision from Apple, not something from the WebKit open source project.

You can file a bug with Apple if you, but this WebKit bug is not valid with regards to the WebKit open source project.