Merge pull request #19954 from roscomputing/fix/19941/fix_safari_useragent

fix safari useragent for versions with 3 digits
This commit is contained in:
Roeland Jago Douma 2020-03-15 13:15:40 +01:00 committed by GitHub
commit 0ffa598136
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 1 deletions

View File

@ -82,7 +82,7 @@ class ContentSecurityPolicyNonceManager {
// Firefox 45+ // Firefox 45+
'/^Mozilla\/5\.0 \([^)]+\) Gecko\/[0-9.]+ Firefox\/(4[5-9]|[5-9][0-9])\.[0-9.]+$/', '/^Mozilla\/5\.0 \([^)]+\) Gecko\/[0-9.]+ Firefox\/(4[5-9]|[5-9][0-9])\.[0-9.]+$/',
// Safari 12+ // Safari 12+
'/^Mozilla\/5\.0 \([^)]+\) AppleWebKit\/[0-9.]+ \(KHTML, like Gecko\) Version\/(1[2-9]|[2-9][0-9])\.[0-9]+ Safari\/[0-9.A-Z]+$/', '/^Mozilla\/5\.0 \([^)]+\) AppleWebKit\/[0-9.]+ \(KHTML, like Gecko\) Version\/(?:1[2-9]|[2-9][0-9])\.[0-9]+(?:\.[0-9]+)? Safari\/[0-9.A-Z]+$/',
]; ];
if($this->request->isUserAgent($browserWhitelist)) { if($this->request->isUserAgent($browserWhitelist)) {