kshyju / BrowserDetector

Fast & light weight browser detection & device detection for asp.net core and azure functions
MIT License
30 stars 13 forks source link

HTTP Error 500 on 32-bit Windows OS #1

Closed nixbmu closed 4 years ago

nixbmu commented 4 years ago

When using BrowserDetector in Razor View in ASP.Net Core 2.2 in Chrome and Edge on 32-bit windows machines it gives an Error 500. In Firefox and IE it works fine. In 64-bit OS it works fine in Chrome and Edge as well as in Firefox and IE. Web app hosted on IIS on Windows Server 2012 R2 64-bit

kshyju commented 4 years ago

Thanks! Could you share the stack trace ? Also what was user agent string value ?

nixbmu commented 4 years ago

Capture

This is the output I get in the console. Should I be seeing the trace here, too? (Verbose is selected on Default levels). This is the user agent string: "Mozilla/5.0 (Windows NT 10.0) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/79.0.3945.117 Safari/537.36"

kshyju commented 4 years ago

Apologies for the delay in response.

Apparently The 32 bit UA format was a bit different and it was causing the code to crash. I have made a fix now and ran tests using the ua string you provided and all tests are passing. Please download the latest version (1.0.9) and you should be good.

Thank you for reporting the issue @nixbmu Cheers 🎉

kshyju commented 4 years ago

If you have more UA strings from 32 bit environment, feel free to share it and i will make sure to add tests for that.

You may go to http://bit.ly/request-headers and that should tell you the User-Agent.