Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Edge in Windows 10 S user agent string? Any other way to programmatically detect Windows 10 S?

Is there a way to know if the user is using Windows 10 S? Typically one would use the user-agent string to detect operating system and browser, but I do not believe that Edge on Windows 10 S will have a user-agent string any different from Edge on Windows 10 Home or Pro.

Is there any other way to programmatically detect Windows 10 S from within the browser?

like image 579
Scott Avatar asked Nov 07 '22 19:11

Scott


1 Answers

To detect the operating system on the client machine, your script can analyze the value of two things:

  1. navigator.appVersion
  2. navigator.userAgent

As we can see in Microsoft document that released on 12/15/2016 (User-agent string changes for Microsoft Edge), the Windows NT token's value changes from 6.3 to 10.0 in the EdgeHTML engine and after that Windows 10 S was released on May 2, 2017 that Microsoft didn't mention any changes in navigator.userAgent or navigator.appVersion.

So, Edge on Windows 10 S is no different than Edge on Windows 10 Home or Pro in both of two things above.

Another things that I should to say is:

userAgent is not reliable.

New browsers may start using the same UA, or part of it, as an older browser: you really have no guarantee that the browser agent is indeed the one advertised by this property. (more information)

like image 79
Ali Soltani Avatar answered Nov 15 '22 12:11

Ali Soltani