Open
Description
The DeviceParser incorrectly parses certain user-agent strings, resulting in wrong values for the family, brand, and model fields.
Example of the Issue:
User-Agent String:
Mozilla/5.0 (Linux; Android 6.0.1; Nexus 5x build/mtc19t applewebkit/537.36 (KHTML, like Gecko) Chrome/51.0.2702.81 Mobile Safari/537.36
Current Output:
{
"family": "Nexus 5x build/mtc19t applewebkit/537.36 (KHTML, like Gecko",
"brand": "Generic_Android",
"model": "Nexus 5x build/mtc19t applewebkit/537.36 (KHTML, like Gecko"
}
Expected Output (not sure that it should be exactly like this):
{
"family": "Nexus",
"brand": "Generic_Android",
"model": "Nexus 5x"
}
Steps to Reproduce:
- Provide the above user-agent string to the DeviceParser.
Perhaps this instance of DeviceParser is responsible for this:
DeviceParser(
'Android \\d+?(?:\\.\\d+|)(?:\\.\\d+|); ([^;]+?)(?: Build|\\))',
None,
None,
'Generic_Android',
'$1',
)
Metadata
Metadata
Assignees
Labels
No labels