Skip to content

Commit

Permalink
Improves detection for macOS
Browse files Browse the repository at this point in the history
  • Loading branch information
liviuconcioiu committed Aug 25, 2023
1 parent 18bf812 commit da1cd21
Show file tree
Hide file tree
Showing 2 changed files with 91 additions and 83 deletions.
8 changes: 8 additions & 0 deletions Tests/Parser/fixtures/oss.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3894,3 +3894,11 @@
version: "10"
platform: x64
family: Windows
-
user_agent: StudioDisplay/0.5 (Darwin; 21.4.0; x86_64; 64bit; utf-8)
os:
name: Mac
short_name: MAC
version: "12.3"
platform: x64
family: Mac
166 changes: 83 additions & 83 deletions regexes/oss.yml
Original file line number Diff line number Diff line change
Expand Up @@ -1020,174 +1020,174 @@
##########
# Mac
##########
- regex: 'CFNetwork/.+ Darwin/(?:[\d\.]+).+(?:x86_64|i386|Power%20Macintosh)|(?:x86_64-apple-)?darwin(?:[\d\.]+)|PowerMac|com.apple.Safari.SearchHelper|^Safari'
- regex: '(?:CFNetwork|StudioDisplay)/.+Darwin(?:/|; )(?:[\d\.]+).+(?:x86_64|i386|Power%20Macintosh)|(?:x86_64-apple-)?darwin(?:[\d\.]+)|PowerMac|com.apple.Safari.SearchHelper|^Safari'
name: 'Mac'
versions:
- regex: '(?:x86_64-apple-)?Darwin/?23.0.0'
- regex: '(?:x86_64-apple-)?Darwin(?:/|; )?23.0.0'
version: '14.0'
- regex: '(?:x86_64-apple-)?Darwin/?22.6.0'
- regex: '(?:x86_64-apple-)?Darwin(?:/|; )?22.6.0'
version: '13.5'
- regex: '(?:x86_64-apple-)?Darwin/?22.5.0'
- regex: '(?:x86_64-apple-)?Darwin(?:/|; )?22.5.0'
version: '13.4'
- regex: '(?:x86_64-apple-)?Darwin/?22.4.0'
- regex: '(?:x86_64-apple-)?Darwin(?:/|; )?22.4.0'
version: '13.3'
- regex: '(?:x86_64-apple-)?Darwin/?22.3.0'
- regex: '(?:x86_64-apple-)?Darwin(?:/|; )?22.3.0'
version: '13.2'
- regex: '(?:x86_64-apple-)?Darwin/?22.2.0'
- regex: '(?:x86_64-apple-)?Darwin(?:/|; )?22.2.0'
version: '13.1'
- regex: '(?:x86_64-apple-)?Darwin/?22.1.0'
- regex: '(?:x86_64-apple-)?Darwin(?:/|; )?22.1.0'
version: '13.0.1'
- regex: '(?:x86_64-apple-)?Darwin/?22.0.0'
- regex: '(?:x86_64-apple-)?Darwin(?:/|; )?22.0.0'
version: '13.0'
- regex: '(?:x86_64-apple-)?Darwin/?21.6.0'
- regex: '(?:x86_64-apple-)?Darwin(?:/|; )?21.6.0'
version: '12.5'
- regex: '(?:x86_64-apple-)?Darwin/?21.5.0'
- regex: '(?:x86_64-apple-)?Darwin(?:/|; )?21.5.0'
version: '12.4'
- regex: '(?:x86_64-apple-)?Darwin/?21.4.0'
- regex: '(?:x86_64-apple-)?Darwin(?:/|; )?21.4.0'
version: '12.3'
- regex: '(?:x86_64-apple-)?Darwin/?21.3.0'
- regex: '(?:x86_64-apple-)?Darwin(?:/|; )?21.3.0'
version: '12.2'
- regex: '(?:x86_64-apple-)?Darwin/?21.2.0'
- regex: '(?:x86_64-apple-)?Darwin(?:/|; )?21.2.0'
version: '12.1'
- regex: '(?:x86_64-apple-)?Darwin/?21.1.0'
- regex: '(?:x86_64-apple-)?Darwin(?:/|; )?21.1.0'
version: '12.0.1'
- regex: '(?:x86_64-apple-)?Darwin/?21.0.0'
- regex: '(?:x86_64-apple-)?Darwin(?:/|; )?21.0.0'
version: '12.0'
- regex: '(?:x86_64-apple-)?Darwin/?20.6.0'
- regex: '(?:x86_64-apple-)?Darwin(?:/|; )?20.6.0'
version: '11.5'
- regex: '(?:x86_64-apple-)?Darwin/?20.5.0'
- regex: '(?:x86_64-apple-)?Darwin(?:/|; )?20.5.0'
version: '11.4'
- regex: '(?:x86_64-apple-)?Darwin/?20.4.0'
- regex: '(?:x86_64-apple-)?Darwin(?:/|; )?20.4.0'
version: '11.3'
- regex: '(?:x86_64-apple-)?Darwin/?20.3.0'
- regex: '(?:x86_64-apple-)?Darwin(?:/|; )?20.3.0'
version: '11.2'
- regex: '(?:x86_64-apple-)?Darwin/?20.2.0.*'
- regex: '(?:x86_64-apple-)?Darwin(?:/|; )?20.2.0.*'
version: '11.1'
- regex: '(?:x86_64-apple-)?Darwin/?20.[01].0'
- regex: '(?:x86_64-apple-)?Darwin(?:/|; )?20.[01].0'
version: '11.0'
- regex: '(?:x86_64-apple-)?Darwin/?19.6.0'
- regex: '(?:x86_64-apple-)?Darwin(?:/|; )?19.6.0'
version: '10.15.6'
- regex: '(?:x86_64-apple-)?Darwin/?19.5.0'
- regex: '(?:x86_64-apple-)?Darwin(?:/|; )?19.5.0'
version: '10.15.5'
- regex: '(?:x86_64-apple-)?Darwin/?19.4.0'
- regex: '(?:x86_64-apple-)?Darwin(?:/|; )?19.4.0'
version: '10.15.4'
- regex: '(?:x86_64-apple-)?Darwin/?19.3.0'
- regex: '(?:x86_64-apple-)?Darwin(?:/|; )?19.3.0'
version: '10.15.3'
- regex: '(?:x86_64-apple-)?Darwin/?19.2.0'
- regex: '(?:x86_64-apple-)?Darwin(?:/|; )?19.2.0'
version: '10.15.2'
- regex: '(?:x86_64-apple-)?Darwin/?19.0.0'
- regex: '(?:x86_64-apple-)?Darwin(?:/|; )?19.0.0'
version: '10.15'
- regex: '(?:x86_64-apple-)?Darwin/?18.7.0'
- regex: '(?:x86_64-apple-)?Darwin(?:/|; )?18.7.0'
version: '10.14'
- regex: '(?:x86_64-apple-)?Darwin/?18.6.0'
- regex: '(?:x86_64-apple-)?Darwin(?:/|; )?18.6.0'
version: '10.14.5'
- regex: '(?:x86_64-apple-)?Darwin/?18.5.0'
- regex: '(?:x86_64-apple-)?Darwin(?:/|; )?18.5.0'
version: '10.14.4'
- regex: '(?:x86_64-apple-)?Darwin/?18.2.0'
- regex: '(?:x86_64-apple-)?Darwin(?:/|; )?18.2.0'
version: '10.14.1'
- regex: '(?:x86_64-apple-)?Darwin/?18.0.0'
- regex: '(?:x86_64-apple-)?Darwin(?:/|; )?18.0.0'
version: '10.14'
- regex: '(?:x86_64-apple-)?Darwin/?17.7.0'
- regex: '(?:x86_64-apple-)?Darwin(?:/|; )?17.7.0'
version: '10.13.6'
- regex: '(?:x86_64-apple-)?Darwin/?17.6.0'
- regex: '(?:x86_64-apple-)?Darwin(?:/|; )?17.6.0'
version: '10.13.5'
- regex: '(?:x86_64-apple-)?Darwin/?17.5.0'
- regex: '(?:x86_64-apple-)?Darwin(?:/|; )?17.5.0'
version: '10.13.4'
- regex: '(?:x86_64-apple-)?Darwin/?17.4.0'
- regex: '(?:x86_64-apple-)?Darwin(?:/|; )?17.4.0'
version: '10.13.3'
- regex: '(?:x86_64-apple-)?Darwin/?17.3.0'
- regex: '(?:x86_64-apple-)?Darwin(?:/|; )?17.3.0'
version: '10.13.2'
- regex: '(?:x86_64-apple-)?Darwin/?17.2.0'
- regex: '(?:x86_64-apple-)?Darwin(?:/|; )?17.2.0'
version: '10.13.1'
- regex: '(?:x86_64-apple-)?Darwin/?17.0.0'
- regex: '(?:x86_64-apple-)?Darwin(?:/|; )?17.0.0'
version: '10.13'
- regex: '(?:x86_64-apple-)?Darwin/?16.7.0'
- regex: '(?:x86_64-apple-)?Darwin(?:/|; )?16.7.0'
version: '10.12.6'
- regex: '(?:x86_64-apple-)?Darwin/?16.6.0'
- regex: '(?:x86_64-apple-)?Darwin(?:/|; )?16.6.0'
version: '10.12.5'
- regex: '(?:x86_64-apple-)?Darwin/?16.5.0'
- regex: '(?:x86_64-apple-)?Darwin(?:/|; )?16.5.0'
version: '10.12.4'
- regex: '(?:x86_64-apple-)?Darwin/?16.4.0'
- regex: '(?:x86_64-apple-)?Darwin(?:/|; )?16.4.0'
version: '10.12.3'
- regex: '(?:x86_64-apple-)?Darwin/?16.3.0'
- regex: '(?:x86_64-apple-)?Darwin(?:/|; )?16.3.0'
version: '10.12.2'
- regex: '(?:x86_64-apple-)?Darwin/?16.2.0'
- regex: '(?:x86_64-apple-)?Darwin(?:/|; )?16.2.0'
version: '10.12.2'
- regex: '(?:x86_64-apple-)?Darwin/?16.1.0'
- regex: '(?:x86_64-apple-)?Darwin(?:/|; )?16.1.0'
version: '10.12.1'
- regex: '(?:x86_64-apple-)?Darwin/?16.0.0'
- regex: '(?:x86_64-apple-)?Darwin(?:/|; )?16.0.0'
version: '10.12'
- regex: '(?:x86_64-apple-)?Darwin/?15.6.0'
- regex: '(?:x86_64-apple-)?Darwin(?:/|; )?15.6.0'
version: '10.11.6'
- regex: '(?:x86_64-apple-)?Darwin/?15.5.0'
- regex: '(?:x86_64-apple-)?Darwin(?:/|; )?15.5.0'
version: '10.11.5'
- regex: '(?:x86_64-apple-)?Darwin/?15.4.0'
- regex: '(?:x86_64-apple-)?Darwin(?:/|; )?15.4.0'
version: '10.11.4'
- regex: '(?:x86_64-apple-)?Darwin/?15.3.0'
- regex: '(?:x86_64-apple-)?Darwin(?:/|; )?15.3.0'
version: '10.11.3'
- regex: '(?:x86_64-apple-)?Darwin/?15.2.0'
- regex: '(?:x86_64-apple-)?Darwin(?:/|; )?15.2.0'
version: '10.11.2'
- regex: 'CFNetwork/760'
version: '10.11'
- regex: '(?:x86_64-apple-)?Darwin/?14.5.0'
- regex: '(?:x86_64-apple-)?Darwin(?:/|; )?14.5.0'
version: '10.10.5'
- regex: '(?:x86_64-apple-)?Darwin/?14.4.0'
- regex: '(?:x86_64-apple-)?Darwin(?:/|; )?14.4.0'
version: '10.10.4'
- regex: '(?:x86_64-apple-)?Darwin/?14.3.0'
- regex: '(?:x86_64-apple-)?Darwin(?:/|; )?14.3.0'
version: '10.10.3'
- regex: '(?:x86_64-apple-)?Darwin/?14.1.0'
- regex: '(?:x86_64-apple-)?Darwin(?:/|; )?14.1.0'
version: '10.10.2'
- regex: '(?:x86_64-apple-)?Darwin/?14.0.0'
- regex: '(?:x86_64-apple-)?Darwin(?:/|; )?14.0.0'
version: '10.10'
- regex: '(?:x86_64-apple-)?Darwin/?13.4.0'
- regex: '(?:x86_64-apple-)?Darwin(?:/|; )?13.4.0'
version: '10.9.5'
- regex: '(?:x86_64-apple-)?Darwin/?13.3.0'
- regex: '(?:x86_64-apple-)?Darwin(?:/|; )?13.3.0'
version: '10.9.4'
- regex: '(?:x86_64-apple-)?Darwin/?13.2.0'
- regex: '(?:x86_64-apple-)?Darwin(?:/|; )?13.2.0'
version: '10.9.3'
- regex: '(?:x86_64-apple-)?Darwin/?13.1.0'
- regex: '(?:x86_64-apple-)?Darwin(?:/|; )?13.1.0'
version: '10.9.2'
- regex: '(?:x86_64-apple-)?Darwin/?13.0.0'
- regex: '(?:x86_64-apple-)?Darwin(?:/|; )?13.0.0'
version: '10.9.0'
- regex: '(?:x86_64-apple-)?Darwin/?12.6.0'
- regex: '(?:x86_64-apple-)?Darwin(?:/|; )?12.6.0'
version: '10.8.5'
- regex: '(?:x86_64-apple-)?Darwin/?12.5.0'
- regex: '(?:x86_64-apple-)?Darwin(?:/|; )?12.5.0'
version: '10.8.5'
- regex: '(?:x86_64-apple-)?Darwin/?12.4.0'
- regex: '(?:x86_64-apple-)?Darwin(?:/|; )?12.4.0'
version: '10.8.4'
- regex: '(?:x86_64-apple-)?Darwin/?12.3.0'
- regex: '(?:x86_64-apple-)?Darwin(?:/|; )?12.3.0'
version: '10.8.3'
- regex: '(?:x86_64-apple-)?Darwin/?12.2.0'
- regex: '(?:x86_64-apple-)?Darwin(?:/|; )?12.2.0'
version: '10.8.2'
- regex: '(?:x86_64-apple-)?Darwin/?12.1.0'
- regex: '(?:x86_64-apple-)?Darwin(?:/|; )?12.1.0'
version: '10.8.1'
- regex: '(?:x86_64-apple-)?Darwin/?11.5.0'
- regex: '(?:x86_64-apple-)?Darwin(?:/|; )?11.5.0'
version: '10.7.5'
- regex: '(?:x86_64-apple-)?Darwin/?11.4.2'
- regex: '(?:x86_64-apple-)?Darwin(?:/|; )?11.4.2'
version: '10.7.5'
- regex: '(?:x86_64-apple-)?Darwin/?11.4.0'
- regex: '(?:x86_64-apple-)?Darwin(?:/|; )?11.4.0'
version: '10.7.4'
- regex: '(?:x86_64-apple-)?Darwin/?11.3.0'
- regex: '(?:x86_64-apple-)?Darwin(?:/|; )?11.3.0'
version: '10.7.3'
- regex: '(?:x86_64-apple-)?Darwin/?11.2.0'
- regex: '(?:x86_64-apple-)?Darwin(?:/|; )?11.2.0'
version: '10.7.2'
- regex: '(?:x86_64-apple-)?Darwin/?11.1.0'
- regex: '(?:x86_64-apple-)?Darwin(?:/|; )?11.1.0'
version: '10.7.1'
- regex: '(?:x86_64-apple-)?Darwin/?10.8.0'
- regex: '(?:x86_64-apple-)?Darwin(?:/|; )?10.8.0'
version: '10.6.8'
- regex: '(?:x86_64-apple-)?Darwin/?10.7.[34]'
- regex: '(?:x86_64-apple-)?Darwin(?:/|; )?10.7.[34]'
version: '10.6.7'
- regex: '(?:x86_64-apple-)?Darwin/?10.3.0'
- regex: '(?:x86_64-apple-)?Darwin(?:/|; )?10.3.0'
version: '10.6.3'
- regex: '(?:x86_64-apple-)?Darwin/?10.0.0'
- regex: '(?:x86_64-apple-)?Darwin(?:/|; )?10.0.0'
version: '10.6'
- regex: '(?:x86_64-apple-)?Darwin/?9.8.0'
- regex: '(?:x86_64-apple-)?Darwin(?:/|; )?9.8.0'
version: '10.5.8'
- regex: '(?:x86_64-apple-)?Darwin/?9.7.1'
- regex: '(?:x86_64-apple-)?Darwin(?:/|; )?9.7.1'
version: '10.5.7'
- regex: '(?:x86_64-apple-)?Darwin/?9.6.2'
- regex: '(?:x86_64-apple-)?Darwin(?:/|; )?9.6.2'
version: '10.5.6'
- regex: '(?:x86_64-apple-)?Darwin/?9.5.[05]'
- regex: '(?:x86_64-apple-)?Darwin(?:/|; )?9.5.[05]'
version: '10.5.5'

- regex: 'Macintosh;Mac OS X \((\d+[\.\d]+)\);'
Expand Down

0 comments on commit da1cd21

Please sign in to comment.