Yet Another UserAgent Analyzer .NET Standard Porting
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.

README.md

Yauaa: Yet Another UserAgent Analyzer

This is a .NET porting of Java library that tries to parse and analyze the useragent string and extract as many relevant attributes as possible.

You can see the original project at this link: https://github.com/nielsbasjes/yauaa

A bit more background about this useragent parser can be found in this blog which the author Niels Basjes wrote about it: https://techlab.bol.com/making-sense-user-agent-string/

The Java documentation can be found here https://yauaa.basjes.nl, soon will be provided a .NET documentation specific for this project

You can download the .nuget package there: https://www.nuget.org/packages/OrbintSoft.Yauaa.NetStandard.Analyzer

STATUS: 5.3-beta.x latest stable

You can consider this version stable and equivalent to the same 5.3 Java version in features

I can't release the version 5.3 as stable because I am planning a major code refactoring that will break the compabilities with public API.

A stable version will be relased as soon as I complete the following tasks:

  • Improve performance
  • Add more tests
  • Make more C# like
  • Clean the code
  • Add documenation

Consider to contribute to the project to release soon a stable version

Example output

As an example the useragent of a phone:

Mozilla/5.0 (Linux; Android 7.0; Nexus 6 Build/NBD90Z) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/53.0.2785.124 Mobile Safari/537.36

is converted into this set of fields:

Field name Value
DeviceClass 'Phone'
DeviceName 'Google Nexus 6'
DeviceBrand 'Google'
OperatingSystemClass 'Mobile'
OperatingSystemName 'Android'
OperatingSystemVersion '7.0'
OperatingSystemNameVersion 'Android 7.0'
OperatingSystemVersionBuild 'NBD90Z'
LayoutEngineClass 'Browser'
LayoutEngineName 'Blink'
LayoutEngineVersion '53.0'
LayoutEngineVersionMajor '53'
LayoutEngineNameVersion 'Blink 53.0'
LayoutEngineNameVersionMajor 'Blink 53'
AgentClass 'Browser'
AgentName 'Chrome'
AgentVersion '53.0.2785.124'
AgentVersionMajor '53'
AgentNameVersion 'Chrome 53.0.2785.124'
AgentNameVersionMajor 'Chrome 53'

Try it!

You can try online the Java version with your own browser here: https://try.yauaa.basjes.nl/.

Soon will be available a test with .NET library

Meanwhile, don't forget to download the .nuget package to try by yourself: https://www.nuget.org/packages/OrbintSoft.Yauaa.NetStandard.Analyzer

NOTES

  1. This runs under a "Free quota" on Google AppEngine. If this quota is exceeded then it will simply become unavailable for that day.
  2. After a while of inactivity the instance is terminated so the first page may take 15-30 seconds to load.
  3. If you really like this then run it on your local systems. It's much faster that way.

Contribute

If you like this project or if has business value for you then don't hesitate to support me or the author.

To support the original project you can make a small donation to: Donations via PayPal Niels Basjes, Original Author

To support this porting, don't esitate to contribute to code sending a Pull request

Otherwise a small paypal donation can also be apreciated Donations via PayPal Stefano Balzarotti, Author of porting

Don't forget to be thankful to the original author Nicolaas Basjes, he did most of the effort.

License

Yet Another UserAgent Analyzer .NET Standard
Porting realized by Balzarotti Stefano, Copyright (C) OrbintSoft

Original Author and License:

Yet Another UserAgent Analyzer
Copyright (C) 2013-2018 Niels Basjes

Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at

https://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.

All rights should be reserved to the original author Niels Basjes