Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unsupported useragent Outlook mail app for iOS #439

Open
ZainW opened this issue Jan 22, 2020 · 4 comments
Open

Unsupported useragent Outlook mail app for iOS #439

ZainW opened this issue Jan 22, 2020 · 4 comments

Comments

@ZainW
Copy link

ZainW commented Jan 22, 2020

Description

Unsupported User agent request

ua: "Outlook-iOS/719.3623017.prod.iphone (4.20.0)"

This is the user agent for the outlook application on IOS

How to reproduce

browser = Browser.new('Outlook-iOS/719.3623017.prod.iphone (4.20.0)')
browser.device.name => "Unknown"
browser.platform.ios? => "true"

What do you expect

I expect that the device name gets resolved to something, ideally IPhone similar to the user agent of the mail/safari apps on iphone

What happened instead

It does not recognize this user agent even though it seems like a pretty coherent one

Software:

  • Rails version: 4.2.x
  • Browser gem version: 3.0.3

Full backtrace

irb(main):010:0> browser = Browser.new('Outlook-iOS/719.3623017.prod.iphone (4.20.0)')
=> #<Browser::Generic:0x00007fcdbb314710 @ua="Outlook-iOS/719.3623017.prod.iphone (4.20.0)", @accept_language=[]>
irb(main):011:0> browser.device.ios?
NoMethodError: undefined method `ios?' for #<Browser::Device:0x00007fcdbb2e4a38>
	from (irb):11
	from /Users/zain/.rbenv/versions/2.4.6/lib/ruby/gems/2.4.0/gems/railties-4.2.10/lib/rails/commands/console.rb:110:in `start'
	from /Users/zain/.rbenv/versions/2.4.6/lib/ruby/gems/2.4.0/gems/railties-4.2.10/lib/rails/commands/console.rb:9:in `start'
	from /Users/zain/.rbenv/versions/2.4.6/lib/ruby/gems/2.4.0/gems/railties-4.2.10/lib/rails/commands/commands_tasks.rb:68:in `console'
	from /Users/zain/.rbenv/versions/2.4.6/lib/ruby/gems/2.4.0/gems/railties-4.2.10/lib/rails/commands/commands_tasks.rb:39:in `run_command!'
	from /Users/zain/.rbenv/versions/2.4.6/lib/ruby/gems/2.4.0/gems/railties-4.2.10/lib/rails/commands.rb:17:in `<top (required)>'
	from script/rails:6:in `require'
	from script/rails:6:in `<main>'
irb(main):012:0> browser.device.mobile?
=> true

Report

[Visit http://user-agent.herokuapp.com and paste the URL here]
unfortunatly cannot run urls in the outlook ios app, if you know how i can definitely give it a try

this is the useragent given by rails for this user : "Outlook-iOS/719.3623017.prod.iphone (4.20.0)"

if I can provide any better information let me know

@fnando
Copy link
Owner

fnando commented Jan 22, 2020

Does this app also exist for other platforms, most notably Android? We'd need those user agents as well.

@ZainW
Copy link
Author

ZainW commented Jan 22, 2020

I can get you an android useragent tomorrow using the outlook app as well

@ZainW
Copy link
Author

ZainW commented Jan 23, 2020

@fnando i get something more traditional with the outlook for android application

ua: "Mozilla/5.0 (Linux; Android 10; Pixel 4 XL Build/QQ1B.200105.004; wv) AppleWebKit/537.36 (KHTML, like Gecko) Version/4.0 Chrome/79.0.3945.136 Mobile Safari/537.36"

hope that helps!

@fnando
Copy link
Owner

fnando commented Feb 25, 2020

Yeah, we can't detect it on Android devices, as it doesn't return any hints about outlook itself. I'm unsure about the right approach here. 🤔

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants