I am using aws-amplify 4.3.15(latest) in my react native application with enabled MFA. Now when I try to fetch the list of authorized devices, I do not get a proper result for Android devices.
cognitoUser.listDevices() gives me array of devices, but the DeviceAttribute device_name doesn't say Android or something like that. Instead, I get "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/98.0.4758.102 Safari/537.36". Also Sometime device_name is not at all there.
This is most probably an issue with device tracking and detection. Please help if anyone went through a similar situation.
Related
I'd like to use Chrome to emulate different devices to run my frontend tests on different emulators. in the documentation, I found the following example
And driver.emulateDevice(375, 812, 'Mozilla/5.0 (iPhone; CPU iPhone OS 13_2_3 like Mac OS X) AppleWebKit/605.1.15 (KHTML, like Gecko) Version/13.0.3 Mobile/15E148 Safari/604.1')
where can I get a list of different options?
That is completely up to you, Karate just takes the string you provide and uses it "as is".
For further research into what that string is all about, you can refer this: https://wicg.github.io/ua-client-hints/
When i printed
request.user_agent
its giving:
Mozilla/5.0 (Macintosh; Intel Mac OS X 10_12_4) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/72.0.3626.119 Safari/537.36
I need a way to separate browser, os, devise from the above answer and store the in database.
I'd recommend taking a look at one of the many excellent gems in this space
Hi i'm developping an ionic 3 app and i'd like to know the version of Safari used in iOS simulators, anyone know how to get it ?
Do you want to know the user agent string? You can grab it by visiting one of many sites, eg: http://www.whatsmyua.info?
There's a great listing of Safari user agents at:
https://developers.whatismybrowser.com/useragents/explore/software_name/safari/
You can sort by version number, operating syste (OS X/iPad/iPhone etc)
iPhone simulator user agents will have the iPhone Simulator fragment in them, for example:
https://developers.whatismybrowser.com/useragents/parse/18845-safari-ios-iphone-webkit
Mozilla/5.0 (iPhone Simulator; CPU iPhone OS 5_1 like Mac OS X) AppleWebKit/534.46 (KHTML, like Gecko) Version/5.1 Mobile/9B176 Safari/7534.48.3
I am trying to identify and do some study on what user agent is sending request to our application.
when i execute the request in chrome i see that it says
"Mozilla/5.0 (Macintosh; Intel Mac OS X 10_10_5) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/54.0.2840.71 Safari/537.36"
when i execute it from safari it says
Mozilla/5.0 (Macintosh; Intel Mac OS X 10_10_5) AppleWebKit/602.1.50 (KHTML, like Gecko) Version/10.0 Safari/602.1.50
when u execute it from mozilla it says
Mozilla/5.0 (Macintosh; Intel Mac OS X 10.10; rv:49.0) Gecko/20100101 Firefox/49.0
Why does it say "Mozilla/5.0" for all requests and for chrome specifically it lists all mozilla, chrome and safari.
Can any one please explain why is this the case? Thanks.
User agent strings are a mess, and it is very difficult to write code to get accurate information from them. (See this link for a detailed history of why).
If you just want to gather statistics, try adding Google Analytics to your front end, or use a library that specializes in parsing user agent strings on your back end, such as MobileDetect for PHP.
If you want to do something different depending on what features the browser supports, try detecting support for that feature instead of the browser version. Modernizr is great for this.
When someone accesses a site via a WebView in an iPhone app, is there a reliable way (JavaScript or server-side) to tell what app is being used? It seems like the user agent string can tell me if it's from Safari or not, but not what precise app is being used if it's not Safari, unless a custom user agent has been specified by the app's programmer (which is not often).
I'd like to be able to tell more precisely what exact app is being used in order to serve [slightly] customised content. The identifier doesn't need to be human-readable, just app-sepcific (so e.g. a bundle ID would be fine).
Example (and not useful) user agents:
From Safari: "Mozilla/5.0 (iPhone; U; CPU iPhone OS 3_1_2 like Mac OS X; en-us) AppleWebKit/528.18 (KHTML, like Gecko) Version/4.0 Mobile/7D11 Safari/528.16"
Most Apps:
"Mozilla/5.0 (iPhone; U; CPU iPhone OS 3_1_2 like Mac OS X; en-us) AppleWebKit/528.18 (KHTML, like Gecko) Mobile/7D11"
I tried to write just "Nope", but answers are required to be at least 15 characters long...