Skip to content
This repository was archived by the owner on Oct 29, 2025. It is now read-only.

Commit 5213668

Browse files
Merge pull request #256 from PerimeterX/release/v3.5.0
Release/v3.5.0 to master
2 parents 78deb97 + 2e28c11 commit 5213668

File tree

17 files changed

+2780
-72
lines changed

17 files changed

+2780
-72
lines changed

.github/workflows/ci.yml

Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
name: ci
2+
on: pull_request
3+
jobs:
4+
lint:
5+
runs-on: ubuntu-latest
6+
steps:
7+
- name: Checkout code
8+
uses: actions/checkout@v2
9+
- name: Install dependencies
10+
run: npm install
11+
- name: Run linter
12+
run: npm run lint
13+
unit-test:
14+
runs-on: ubuntu-latest
15+
strategy:
16+
matrix:
17+
node: [ 10, 12, 14, 16, lts/* ]
18+
steps:
19+
- name: Checkout code
20+
uses: actions/checkout@v2
21+
- name: Setup node
22+
uses: actions/setup-node@v3
23+
with:
24+
node-version: ${{ matrix.node }}
25+
- name: Install dependencies
26+
run: npm install
27+
- name: Run unit tests
28+
run: npm run test

.travis.yml

Lines changed: 0 additions & 15 deletions
This file was deleted.

CHANGELOG.md

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,16 @@ All notable changes to this project will be documented in this file.
55
The format is based on [Keep a Changelog](http://keepachangelog.com/)
66
and this project adheres to [Semantic Versioning](http://semver.org/).
77

8+
## [3.5.0] - 2022-10-23
9+
10+
### Added
11+
12+
- Support for `px_custom_first_party_path` configuration
13+
14+
### Changed
15+
16+
- Updated dependencies
17+
818
## [3.4.3] - 2022-06-30
919

1020
### Fixed

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
[PerimeterX](http://www.perimeterx.com) Shared base for NodeJS enforcers
77
=============================================================
88

9-
> Latest stable version: [v3.4.3](https://www.npmjs.com/package/perimeterx-node-core)
9+
> Latest stable version: [v3.5.0](https://www.npmjs.com/package/perimeterx-node-core)
1010
1111
This is a shared base implementation for PerimeterX Express enforcer and future NodeJS enforcers. For a fully functioning implementation example, see the [Node-Express enforcer](https://github.com/PerimeterX/perimeterx-node-express/) implementation.
1212

lib/extract_field/credentials_intelligence/ICredentialsIntelligenceProtocol.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
class ICredentialsIntelligenceProtocol {
2+
// eslint-disable-next-line no-unused-vars
23
ProcessCredentials(username, password) {
34
throw new Error('Unimplemented method!');
45
}

lib/extract_field/credentials_intelligence/V2CredentialsIntelligenceProtocol.js

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,6 @@ class V2CredentialsIntelligenceProtocol extends ICredentialsIntelligenceProtocol
4343
}
4444
}
4545

46-
4746
module.exports = {
4847
V2CredentialsIntelligenceProtocol
4948
};

lib/pxcdenforcer.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ function handleCSP(response, cspData, vid) {
3838
}
3939
}
4040
} catch (e) {
41-
// CSP couldnt be read, continue without it
41+
// CSP couldn't be read, continue without it
4242
console.log(`Exception Caught in HandleCSP. error: ${e}`);
4343
}
4444
}

lib/pxclient.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ const {
1111
CI_CREDENTIALS_COMPROMISED_FIELD,
1212
GQL_OPERATION_TYPE_FIELD,
1313
GQL_OPERATION_NAME_FIELD
14-
} = require('./utils/constants')
14+
} = require('./utils/constants');
1515

1616
class PxClient {
1717
constructor() {

lib/pxconfig.js

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -71,6 +71,7 @@ class PxConfig {
7171
['FILTER_BY_IP', 'px_filter_by_ip'],
7272
['FILTER_BY_USERAGENT', 'px_filter_by_user_agent'],
7373
['FILTER_BY_METHOD', 'px_filter_by_http_method'],
74+
['PX_CUSTOM_FIRST_PARTY_PATH', 'px_custom_first_party_path'],
7475
['PXHD_SECURE', 'px_pxhd_secure_enabled'],
7576
['BACKEND_URL', 'px_backend_url'],
7677
['CUSTOM_COOKIE_HEADER', 'px_custom_cookie_header'],
@@ -315,6 +316,7 @@ function pxDefaultConfig() {
315316
PXHD_SECURE: false,
316317
BACKEND_URL: '',
317318
CUSTOM_COOKIE_HEADER: '',
319+
PX_CUSTOM_FIRST_PARTY_PATH: '',
318320
ENABLE_LOGIN_CREDS_EXTRACTION: false,
319321
LOGIN_CREDS_EXTRACTION: [],
320322
CREDENTIALS_INTELLIGENCE_VERSION: CIVersion.V2,
@@ -374,6 +376,7 @@ const allowedConfigKeys = [
374376
'px_pxhd_secure_enabled',
375377
'px_backend_url',
376378
'px_custom_cookie_header',
379+
'px_custom_first_party_path',
377380
'px_login_credentials_extraction_enabled',
378381
'px_login_credentials_extraction',
379382
'px_credentials_intelligence_version',

lib/pxcontext.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -105,6 +105,7 @@ class PxContext {
105105
}
106106

107107
areCredentialsCompromised() {
108+
// eslint-disable-next-line eqeqeq
108109
return (this.pxde && this.pxde['breached_account'] && this.pxdeVerified) != null;
109110
}
110111
}

0 commit comments

Comments
 (0)