karlcow / otsukare.info

otsukare.info is my pro blog (English)
Creative Commons Zero v1.0 Universal
2 stars 0 forks source link

Encyclopedia Of Broken UserAgent String Detections #11

Open karlcow opened 2 years ago

karlcow commented 2 years ago

You may comment on Encyclopedia Of Broken UserAgent String Detections - January 14, 2022

Haroenv commented 2 years ago

There's a little typo in the second code sample, the comment still mentions going to the wrong branch instead of something like goes to supported, as expected

karlcow commented 2 years ago

@Haroenv ooops indeed. Thanks for catching this. I will fix it.

souryavarenya commented 2 years ago

Hi! Just came across the article and had a thought. Wouldn't it be better to leave current user agent strings at "Firefox/99.99.xx" (or so) and instead add a new keyword, say "Firefox-x/102.22.xx". This way you keep old website unbroken and sites relying on modern features of greater than version 100 can (must) use nicer libraries/methods to parse version.

I'm sure someone in Firefox/Chrome(ium) team would have considered this option. Are there any glaring issues with such an approach? I couldn't find any discussions on Reddit or other forums about this idea.

karlcow commented 2 years ago

@souryavarenya sorry for replying so late. Any modifications in the structure of the User Agent string will create detection issues. When changing the keyword for the browser name, we are opening an even bigger can of worms. That's the unfortunate reality of the user agent string minefield.

The transition for both Google and Mozilla has been less painful than expected.