diff --git a/nextjs/csp/policies/ad.ts b/nextjs/csp/policies/ad.ts index 83a8f2e1d5..de1f031004 100644 --- a/nextjs/csp/policies/ad.ts +++ b/nextjs/csp/policies/ad.ts @@ -1,58 +1,58 @@ -import Base64 from "crypto-js/enc-base64"; -import sha256 from "crypto-js/sha256"; -import type CspDev from "csp-dev"; +import Base64 from 'crypto-js/enc-base64'; +import sha256 from 'crypto-js/sha256'; +import type CspDev from 'csp-dev'; -import { connectAdbutler, placeAd } from "ui/shared/ad/adbutlerScript"; +import { connectAdbutler, placeAd } from 'ui/shared/ad/adbutlerScript'; export function ad(): CspDev.DirectiveDescriptor { return { - "connect-src": [ + 'connect-src': [ // coinzilla - "coinzilla.com", - "*.coinzilla.com", - "https://request-global.czilladx.com", + 'coinzilla.com', + '*.coinzilla.com', + 'https://request-global.czilladx.com', // slise - "*.slise.xyz", + '*.slise.xyz', // hype - "api.hypelab-staging.com", - "api.hypelab.com", - "d1q98dzwj6s2rb.cloudfront.net", - "*.ixncdn.com", - "api.jxncdn.com", + 'api.hypelab-staging.com', + 'api.hypelab.com', + 'd1q98dzwj6s2rb.cloudfront.net', + '*.ixncdn.com', + 'api.jxncdn.com', ], - "frame-src": [ + 'frame-src': [ // coinzilla - "https://request-global.czilladx.com", + 'https://request-global.czilladx.com', ], - "script-src": [ + 'script-src': [ // coinzilla - "coinzillatag.com", + 'coinzillatag.com', // adbutler - "servedbyadbutler.com", - `'sha256-${Base64.stringify(sha256(connectAdbutler))}'`, - `'sha256-${Base64.stringify(sha256(placeAd ?? ""))}'`, + 'servedbyadbutler.com', + `'sha256-${ Base64.stringify(sha256(connectAdbutler)) }'`, + `'sha256-${ Base64.stringify(sha256(placeAd ?? '')) }'`, // slise - "*.slise.xyz", + '*.slise.xyz', - "cdn.jsdelivr.net", + 'cdn.jsdelivr.net', // hype - "'unsafe-eval'", + '\'unsafe-eval\'', ], - "img-src": [ + 'img-src': [ // coinzilla - "cdn.coinzilla.io", + 'cdn.coinzilla.io', // adbutler - "servedbyadbutler.com", + 'servedbyadbutler.com', ], - "font-src": [ + 'font-src': [ // coinzilla - "https://request-global.czilladx.com", + 'https://request-global.czilladx.com', ], }; } diff --git a/yarn.lock b/yarn.lock index 9d0cd831b6..ae0f3841da 100644 --- a/yarn.lock +++ b/yarn.lock @@ -10961,14 +10961,9 @@ husky@^8.0.0: resolved "https://registry.yarnpkg.com/husky/-/husky-8.0.1.tgz#511cb3e57de3e3190514ae49ed50f6bc3f50b3e9" integrity sha512-xs7/chUH/CKdOCs7Zy0Aev9e/dKOMZf3K1Az1nar3tzlv0jfqnYtu235bstsWTmXOR0EfINrPa97yy4Lz6RiKw== -hypelab-react@./hypelab-react-0.5.1.tgz: - version "0.5.1" - resolved "./hypelab-react-0.5.1.tgz#8a4e108934677d9f344cad9d4d7aafbfb50bb2ac" - -hypelab-react@^0.5.0: - version "0.5.0" - resolved "https://registry.yarnpkg.com/hypelab-react/-/hypelab-react-0.5.0.tgz#27fd56016f73cdac01fb3d0aac716842170ec383" - integrity sha512-5htdSf60gcn9MGUaffLjljd1GtSAFpIbHMo4Os9NXCAdID73u1R9M2ON44Wtf7+DAwfB2JfJoDAb395p9eQ9wg== +hypelab-react@./hypelab-react-0.5.2.tgz: + version "0.5.2" + resolved "./hypelab-react-0.5.2.tgz#64bf72c27b0fa275c003171edaae37df9361cb56" iconv-lite@0.6, iconv-lite@0.6.3: version "0.6.3"