Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
51 changes: 51 additions & 0 deletions .snyk
Original file line number Diff line number Diff line change
@@ -0,0 +1,51 @@
# Snyk (https://snyk.io) policy file
version: v1.25.0
ignore:
SNYK-JS-DOMPURIFY-16131135:
- '*':
reason: >-
DOMPurify v3 (which fixes this) dropped IE11 support. Lock v13
maintains IE11 compatibility and cannot upgrade to v3.
expires: '2027-01-01T00:00:00.000Z'
SNYK-JS-DOMPURIFY-8722251:
- '*':
reason: >-
DOMPurify v3 (which fixes this) dropped IE11 support. Lock v13
maintains IE11 compatibility and cannot upgrade to v3.
expires: '2027-01-01T00:00:00.000Z'
SNYK-JS-DOMPURIFY-16078387:
- '*':
reason: >-
DOMPurify v3 (which fixes this) dropped IE11 support. Lock v13
maintains IE11 compatibility and cannot upgrade to v3.
expires: '2027-01-01T00:00:00.000Z'
SNYK-JS-DOMPURIFY-15810938:
- '*':
reason: >-
DOMPurify v3 (which fixes this) dropped IE11 support. Lock v13
maintains IE11 compatibility and cannot upgrade to v3.
expires: '2027-01-01T00:00:00.000Z'
SNYK-JS-DOMPURIFY-15874903:
- '*':
reason: >-
DOMPurify v3 (which fixes this) dropped IE11 support. Lock v13
maintains IE11 compatibility and cannot upgrade to v3.
expires: '2027-01-01T00:00:00.000Z'
SNYK-JS-DOMPURIFY-15874905:
- '*':
reason: >-
DOMPurify v3 (which fixes this) dropped IE11 support. Lock v13
maintains IE11 compatibility and cannot upgrade to v3.
expires: '2027-01-01T00:00:00.000Z'
SNYK-JS-DOMPURIFY-15371386:
- '*':
reason: >-
DOMPurify v3 (which fixes this) dropped IE11 support. Lock v13
maintains IE11 compatibility and cannot upgrade to v3.
expires: '2027-01-01T00:00:00.000Z'
SNYK-JS-DOMPURIFY-15371376:
- '*':
reason: >-
DOMPurify v3 (which fixes this) dropped IE11 support. Lock v13
maintains IE11 compatibility and cannot upgrade to v3.
expires: '2027-01-01T00:00:00.000Z'
18 changes: 0 additions & 18 deletions css/social_icons.styl

Large diffs are not rendered by default.

6 changes: 5 additions & 1 deletion karma.conf.js
Original file line number Diff line number Diff line change
Expand Up @@ -115,9 +115,13 @@ module.exports = function (config) {
chrome_headless: {
base: 'Chrome',
flags: ['--headless']
},
ChromeHeadlessNoSandbox: {
base: 'ChromeHeadless',
flags: ['--no-sandbox']
}
},

browsers: ['bs_chrome_windows']
browsers: [process.env.CI ? 'ChromeHeadlessNoSandbox' : 'ChromeHeadless']
});
};
8 changes: 4 additions & 4 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -120,22 +120,22 @@
"webpack-dev-server": "^4.11.1"
},
"dependencies": {
"auth0-js": "^9.27.0",
"auth0-js": "^9.29.0",
"auth0-password-policies": "^1.0.2",
"blueimp-md5": "^2.19.0",
"classnames": "^2.3.2",
"dompurify": "^2.5.4",
"immutable": "^3.7.6",
"immutable": "^3.8.3",
"jsonp": "^0.2.1",
"password-sheriff": "^1.1.1",
"prop-types": "^15.8.0",
"qs": "^6.10.3",
"qs": "^6.14.2",
"react": "^18.2.0",
"react-dom": "^18.2.0",
"react-transition-group": "^2.2.1",
"trim": "^1.0.1",
"url-join": "^1.1.0",
"validator": "^13.6.0"
"validator": "^13.15.22"
},
"ccu": {
"name": "lock",
Expand Down
3 changes: 0 additions & 3 deletions src/connection/social/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -22,11 +22,9 @@ export const STRATEGIES = {
'google-oauth2': 'Google',
instagram: 'Instagram',
linkedin: 'LinkedIn',
miicard: 'miiCard',
paypal: 'PayPal',
'paypal-sandbox': 'PayPal Sandbox',
planningcenter: 'Planning Center',
renren: '人人',
salesforce: 'Salesforce',
'salesforce-community': 'Salesforce Community',
'salesforce-sandbox': 'Salesforce (sandbox)',
Expand All @@ -43,7 +41,6 @@ export const STRATEGIES = {
windowslive: 'Microsoft',
wordpress: 'Wordpress',
yahoo: 'Yahoo!',
yammer: 'Yammer',
yandex: 'Yandex',
weibo: '新浪微博',
line: 'Line'
Expand Down
4 changes: 2 additions & 2 deletions src/i18n.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import React from 'react';
import Immutable, { Map } from 'immutable';
import format from './utils/format';
import { sanitize } from 'dompurify';
import DOMPurify from 'dompurify';
import sync from './sync';
import * as l from './core/index';
import { dataFns } from './utils/data_utils';
Expand All @@ -18,7 +18,7 @@ export function html(m, keyPath, ...args) {
// dangerouslySetInnerHTML input is sanitized using dompurify
// eslint-disable-next-line react/no-danger
return html
? React.createElement('span', { dangerouslySetInnerHTML: { __html: sanitize(html) } })
? React.createElement('span', { dangerouslySetInnerHTML: { __html: DOMPurify.sanitize(html) } })
: null;
}

Expand Down
4 changes: 2 additions & 2 deletions src/sanitizer.js
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
import { addHook } from 'dompurify';
import DOMPurify from 'dompurify';

export function initSanitizer() {
// Extracted from the example at
// https://github.com/cure53/DOMPurify/blob/main/demos/hooks-target-blank-demo.html
addHook('afterSanitizeAttributes', function(node) {
DOMPurify.addHook('afterSanitizeAttributes', function(node) {
// set all elements owning target to target=_blank
if ('target' in node) {
node.setAttribute('target', '_blank');
Expand Down
Loading